I’ve got an idea for a piece of software, but it’s been 20 years since I’ve done any programming. This would be kind of a mix of Amazon.com’s “Other people that bought XXX and liked it also liked YYY” with a barcode scan thrown in.
Is anyone familiar with designing similar types of software, and what programming language do you use for it?
((Ok, you caught me. Mostly I’m thinking of using this as an excuse to go relearn programming.))
Python is a great place to start, It is fairly easy to get started with but also extremely powerful. I believe that Google uses it a lot and it will probably expand a great deal in the near future.
For what sort of platform? Web? PC? Something else?
For me, I occasionally do Windows applications for work. I’m working on a project currently, and I’m developing it in .NET Visual C#. If you’re doing any sort of Windows applications programming, any of the .NET languages will do nicely. Visual Basic is probably the easiest to learn, while C# and C++ seem to be among the more popular languages for expert programmers.
I agree C# is a great language to learn. Once you get a hang of it, you can switch over to Java. Java applications are slowly being replaced by Flash products which do similar things. So Java never caught on like it was supposed to.
If you’re looking for webprogramming PHP is great. It’s open sourced and it has a great community for learning. People on various PHP boards LIKE, I mean they actually LIKE to help beginners so that goes a long way on your learning curve.
Start with C# or PHP and then once you get a solid command on them head to others
For applications which reside and run on the user’s own computer, some flavor of C would definitely be your best bet. C++ is probably the most universally used, but if you’re writing exclusively for Windows, you might prefer C#, and if you’re writing exclusively for Mac, you might prefer Objective C. I put the “exclusively” caveat in there because those two languages are fundamentally integrated into their respective operating systems, and so are more difficult to port to other systems. Everyone supports C++, though (and plain vanilla C, but anything you can do in C, you can do in C++, often easier).
Java is very closely related to C, but typically runs slower, since it adds another layer of abstraction (the “virtual machine”). One tactic is to use Java for the “front end” of an application, handling the user interface, but to pass everything to a “back end” written in some other language that does all the heavy processing.
If you just want to know which languages are popular, try this site. Of course, that doesn’t mean that just because a particular language is popular it will suit you or be appropriate for what you’re trying to accomplish.
Java would be choice as it is fairly OS-agnostic (most Java apps will run on Linux, MAC and Windows without re-compiling). Also check out JavaFX. It lets you write a java app that works on a desktop and then creates a version for a mobile device automagically (resizes display, adapts input methods etc) making your app portable.
If you’re making a website, the most common options are PHP, Java Servlets, or VB.NET.
If you have some sort of barcode reader and you’re going to have a regular windowed application which interfaces with it, probably the reader is only going to have a C interface. You’ll probably want to go with C, C++, or D. If C# can call C functions that’s a good option too, but I suspect it doesn’t since it compiles to bytecode.
As Shagnasty says, Python is a good learner’s language. You can’t really do windowed apps or anything, but really there’s no language that makes windowed apps as easy to make as it seems like it should be, so you’re probably better off to ignore making GUIs while you’re relearning.
It might be a good exercise to search for each language on Indeed.com and see which are most in demand. Of course some jobs are with legacy software, but I’d guess it it’d still a generally informative search.
IMHO, I’ve used C, C++, a bit of Java, and C#, and I’m sticking with C#.
Picking the programming language is easy. Picking the collaborative filtering algorithm and implementing it so that it scales well is very hard. Based on the fact that you don’t know how to program, I’m going to guess that you don’t have an algorithm in mind either. I think it’s great that you want to learn how to program, but you need to start with an easier problem.
(For the record, if I were trying to build a site like this, I’d look very seriously at OCaml.)
That’s a slightly different problem. Netflix wants to more accurately predict how a user will rate a given movie based on their past ratings. The OP wants to compute a ranking of products rather than an estimate of ratings. You can rank by estimating all the ratings and sorting, but you’d have to not care about performance at all to think that’s a good idea.
I would agree that Java’s probably a good choice for getting started. There are things about the language I find irritating (the lack of operator overloading being one) but on the whole it’s pretty decent, fairly easy to learn, and there’s no denying that it’s extremely popular. C# is similar to Java in a lot of ways, but it has many more features. The downside is that its cross-platform support is not as good as Java’s. It is usable on many non-Windows platforms, however (along with a lot of .NET stuff) through Mono.
Python is also excellent choice, IMHO. Lots of fun to use, and its widespread popularity means there are libraries available for Python for just about every purpose imaginable.
I wouldn’t really call C# a flavor of C. It’s related to C about as much as Java is, which is to say it shares the basic style of syntax and not much else. (Well, I guess it shares part of the name, too. ;))
.NET can import functions from native DLLs just fine, so at worst (if the barcode reader only provides static libraries) you’d just have to create a dynamic library wrapper in order to use the scanner with C#.
Technically, you can create wrappers to C from Java or Python or pretty much any language. But I don’t think most people would choose those languages first if they were going to interface to C as a core part of their app.
Hm, slight bug in that code that I forgot to verify there was something in the slot that gets decremented before decrementing, and go back and choose another random value first. Otherwise it should work just fine for almost anyone’s purposes. You might also modify it to limit the max value of any one ID so that there is a minimum spread of alternate products–in case one steals too many points.