You can find the answer in the FAQ I believe... Choose something:
http://learnpythonthehardway.org - deepen your knowledge of Python
http://www.codeabbey.com - beginner's programming exercises
http://www.codingbat.com - interactive exercises for learning Java or Python
etc.
There's a lengthy wiki article on the history of computation methods if people are interested https://en.m.wikipedia.org/wiki/Approximations_of_π
Also here's a simple programming challenge that describes an Ancient Greek method that's neat and converges faster if anyone wants to try it out http://www.codeabbey.com/index/task_view/calculation-of-pi
If you really want to go deep to hardware internals, then probably you may have fun with learning assembly, embedded programming, etc?
I have a few Intel-4004 assembly exercises at my site (similar to projecteuler you've mentioned): http://www.codeabbey.com/index/task_list/assembly
they are accompanied by simple simulator and tutorial.
But of course this is more like a toy. Just to have some special fun or get an idea of "very low level".
I used to work as electronics developer, programming for AVR, 8051 and ARM microchips - we mostly did this in C of course, though I sometimes used respective assembly languages for critical sections.
So probably it would be good to lay your hands on K&R book and learn a bit of C if you are interested in this field.
> By decent paying I mean, 50k would be amazing to be making within 5 years.
You can have twice more than that in 3 or 4 years with Java if you reside in California or New-York for example. To reach 50k in 5 years is not hard even in Russia where I live and work and where prices are far lower. (I switched to Java just 3 years ago and already doubled or tripled my salary compared to what I gain working in C projects)
> I'm approaching 30 and have an unrelated degree
What a coincidence! I was 29 when I switched to java. It was not easy, but still it was possible. And I have only bachelor degree in unrelated field. If this may help or inspire you - here is my story (I wrote it for my company few months ago - and later translated):
The only problem is that you need to work hard enough, to love programming and to feel devotion to this field :)
Just wishing money is not a good motivation.
> I hear C# is another good option
Especially if you work in US. It is somewhat less popular in other countries and I personally like Java more for its great infrastructure (though C# has more developed syntactic features etc.)
However you can succeed and get fat salary in any branch, provided you feel inclination to it and are ready to learn and work enough. On the other hand there is no magic language or technology which will make you millionaire if it is not "your field"... Good luck!
There is my site CodeAbbey - sorry for blatant advertising.
It works exactly as you told:
> You know, step by step, more and more challenging.
as the exercises are sorted by how many people solved them.
Problems themselves contain not only simplest "sum-of-array" things, but has among them exercises dedicated to specific popular algorithms, to some game-programming elements etc. There are also few challenges which could be solved better or worse compared to other participants.
After solving the problem you can browse others' solutions which often is helpful if you are in doubt about effectiveness or style of your code.
There is also a small forum to search or ask for help. At last there are free certificates...
> I'm thinking SPOJ would be good
Verily one of the best sites of competitive programming. Along with CodeForces, TopCoder and alike (be sure it is not easy to find where to enter topcoder's challenges at first glance).
If you are not necessarily seeking for hard competitive programming problems, my site http://www.codeabbey.com is at your service - but it is targeted mainly to beginners or "casual" programmers - to provide them practice in writing small problems and learning popular algorithms.
> Conway's game of life
Exactly! I felt nostalgia reading your answer 'cause I remember when I tried to learn Fortran on my own (about 13 years ago) I started writing this on the second day... It could only work with files because it was MS Fortran 3.31 (I believe 77-th standard)... Hope I can find its code now... :)
> Manual string twiddlings (no regex cheating)
This may be different in different languages. E.g. reverting and rotating string is too easily done in Python
but is a good exercise in C
.
I meekly dare to put here a link to my site with similar small problems since here it is possible not only solve these exercises but also compare solutions with other users.
> Thanks, I think we will work on some website or app that our school can use
I think at least at beginning it is better to avoid such "long" goals. There would be two problems:
So my Plan would be such:
Start with some short exercises (like ones from my collection) and after you will see how the people are working, and how they can be organized into several small teams (probably it would be easier) - you'll be able to choose small project for each such team.
I myself follow this pattern for several years teaching pupils in the school. First three months are dedicated to exercises which are solved by almost all in a single lesson - and during the remaining part of the year we proceed with longer personal projects (and usually with reduced number of pupils).
No, you should not. These problems are mostly puzzles for people who likes math-related puzzles. They are cool, but to be honest it is not about programminig that much.
If you want, you'd better visit my website (created after the manner of ProjectEuler):
Problems here are more "programming-related" and most of them are not that much puzzling (though sometimes it is bit dull, haha). As a bonus, you can see others' solutions after successfully solving each task.
Well, this site also have some math-related problems, but more practical ones...
> More importantly: What are some simple, self-contained tasks (using any system)
There was a nice, though simple course at coursera - they taught to make basic games with Python version running upon the browser's javascript: https://www.coursera.org/course/interactivepython1
Other than that I'm trying to build a collection of coding problems at my site CodeAbbey, but they are mostly about teaching concepts (starting from basics) rather than using some specific game engine or library. Though there still are problems related to games programming etc, e.g.
http://www.codeabbey.com/index/task_list/games
Django is not a language.
It is a web-framework for Python language. If you know "some python" it would be decent choice. You can also try Flask (also for Python) which probably may feel somewhat simpler.
You can host it at PythonAnywhere for free. Here is my short intro for this resource which you can use to try it with "hands on".
My favorite website is definitely http://www.codeabbey.com/
It allows you to try problems in multiple languages and you have to start each problem from scratch (instead of just writing methods).
Also after you solve a problem, you are able to view others solutions which helps expands your know-how!
If you have no much experience in web-development, I believe even free hosting will do well.
I used PythonAnywhere and it feels rather comfortable both with Django or Flask. You can edit files directly there by the way. There was a short tutorial on how to start by the way.
Of other free opportunities I used Google App Engine - though it is somewhat special in its persistence layer.
Yeah, that is really must-give-a-try thing for everyone who have hard time with Java.
I just dare to add here a link about how I struggled with Java myself, and, well, how I win :)
I agree, at the beginning one should write more than read - that is how programming is learned...
But instead of ProjectEuler have a look at my site :)
it is similar, but problems are mostly about programming instead of math. Also you can read solutions of other people (choosing ones in java for example) after solving yourself.
Besides, cool resource of precisely java exercises is here:
There is not such a scale mostly because while all beginners are roughly similar, all Masters usually work in quite different branches so that guru in web-development in PHP have no significant skills in enterprise Java programming - and both of them are very far from embedded development. At the same time PhD in Computer Science may lack any of these industrial skills but be quite proficient in mathematically-backed topics important for web intelligence, search, analytics and realtime advertising for example.
However if you are interested in a kind of practical / algorithmic exercises and small projects, you can visit my site and try to solve problems of different levels. You may easily note (or ask there at forum) that more advanced of them are usually solved by people with specific programming experience - so it would be easy to judge your level simply by comparing to others success.
All these problems can be broken down to categories. Sorting problems, pathfinding problems, backtracking, subset sum, combinatorics, etc. You just learn to recognize them the more you practice. I also recommend taking a course on algorithms (introductory - Algorithms and Data Structures, and then advance to Algorithm Design). Once you recognize which category the problem belongs to, finding a solution boils down to mere implementation (i.e. modifying a canonical solution to fit your needs and maybe optimizing it).
For practice, you can find tons of fun programming challenges of varying degrees of difficulty on http://www.codeeval.com and http://www.codeabbey.com
I dare say this is a great course though it may require you to recollect the math forgotten from school or college - its math-related homeworks are tough enough...:)
And besides Mr. Boneh is one of the best instructors at Coursera I've seen - thanks to him a lot! Well, almost all courses of Stanford are of good quality...
I enjoyed it very much and until I attended I have no idea that it is really very useful. It gives you insight not only on basic algorithms (like caesar's) but also on many popular contemporary ones - many of them are used to hash passwords or encrypt tokens on your (future) websites etc. Because nowadays it is easy to get lost among all of these abbreviations, even simplest like DES / AES / ECB / CBC/ CTR - and even if you have them in API of your language you often do not know how to apply them correctly!
So definitely if you have time to spare - it is a great way to invest it!
By the way this course gives me ideas for few problems on cryptography for my site:
I agree. I never know Python is that popular among novice programmers until I've started my site for beginners.
Viewing submitted solutions I see about 50% of them are in Python, while 35% more surprisingly in C/C++.
So it is worth follow the "general tendency" - moreover that you'll find a lot of help and support of community easily.
A great site to get into writing algorithms for small programs and problem solving is codeabbey.com. You sign up and get points as you solve the problems. You get to see other's answers after you complete yours, too. Do you can see how others have solved the same thing. Kinda cool.
edit: made it a link.
I dare to add a couple of links for this:
> Come up with a project that interests you
https://github.com/karan/projects - "Mega Project List" :)
http://www.codeabbey.com - my collection of exercises
> I'm a teacher
I wonder, in what field of study? Is it math / physics?
Java has rather diverse set of technologies so you can sometimes find two full-stack developers with completely different set of skills. Probably "full-stack" is not well applicable to java world where it could be better to hire several developers for each technology layer.
However I'd say that Spring + Hibernate + JSP are more popular for enterprise applications. Sometimes you'll find a project which uses EJB instead of Spring, JPA instead of Hibernate and probably JSF instead of JSP - but this will look less or more similar.
You may like to read how I myself was kicking about becoming java developer: http://www.codeabbey.com/index/wiki/long-road-of-learning-java
You may try my http://www.codeabbey.com - it does not go far from ProjectEuler, but problems here are not math-related (mainly) and there is a primitive interface to compile / run your solution at remote server (though for more complicated exercises it is not of much use since you'll prefer to run debug them thoroughly).
Like others have said, find more resources because I've taken the Codecademy "courses" and came away feeling like I had learned exactly nothing. There is certainly a large chasm between "I've completed Codecademy" and "Build a project" so in the meantime try sites like code abbey to practice problem solving and get a sense for some basic techniques and algorithms. You may also get project ideas from there, check it out.
> I need help making it so the players can choose between the different available squares with the cursor, or maybe by pressing enter or something.
Then probably it is better simply to require user enter the number of the square or its coordinates.
> but i don't know how to do that without progressing through each of the squares individually
Once again if you do not know better way, then you can simply reprint the whole field. Of course this kind of interface is not very sexy but this is quite Ok for your learning.
Tricks with positioning cursor could be achieved through some platform-specific library or ANSI escape sequences - but probably it is not worth to kick about these vague approaches. You'd better learn creating graphic interface later.
Probably you can start with interface like this:
http://www.codeabbey.com/index/task_view/tic-tac-toe
P.S. Another trick you can use - to create secondary 2d-array (say 40*25) to serve as your "virtual screen". So you will insert characters in it where you like and when all is ready - just print it out line by line to make a "picture".
> Alternatively you might want to look into a process called 'scraping':
and by the way you may look at this exercise prepared by me on scraping if you want to get some practice before abusing real sites.
You could not learn to play piano just by reading the book. You need gammas, exercises, studies... Much work :)
Though the matter with programming is somewhat different it still requires exercises to be worked through by head and hands.
I prefer books which supply exercises along, but there is not too many of them. There are also books collecting only exercises like Etudes for Programmers though it is not brand new book.
Due to lack of plain exercises I decided to create my own collection.
> this project is so pointless, I've written programs that were hundreds of lines long
Funny - I even tried to create a web-site with a collection of "pointless" exercises:
where users can practice their favorite languages, browse others' solutions and eventually learn some useful algorithms, tricks, data structures...
At my own site I tried to collect more diverse exercises - which may help to understand better how programming can be useful. Additionally there are even few exercises on building basic web-apps - which could be tried, for example, by deploying them to pythonanywhere (there were some instructions).
Also there was a funny resource which you may find interesting:
> So, assembly it is. Any advices? Any sites?
If you want to have some fun, I can offer Intel-4004 assembly :)
It is the grandparent of modern CPUs - probably the first CPU which became widely available (back in about 1970). Its command system is comparatively small - you'll need to read only about 20 instructions - so you'll be able to start very fast.
I once created emulator and added several problems about this version of assembly to my site:
http://www.codeabbey.com/index/task_list/assembly
Starting with the first of them you'll be able to find tutorial, which allows learning 4004 instructions without any additional materials. There are also simple online interpreter and its offline version which you can download to play locally (in Python).
Another Idea
If you are resolute to write in some modern Assembly - I suggest you try AVR Assembly for Atmel chips. You can purchase some small Arduino board to play with... It is a bit more hardcore, but also very fun.
It's rather simple and I once decided to create similar, to build some skills in web-dev etc (as I have very few by that time). It took from me few days to create and deploy a working prototype. (I invented the name CodeAbbey later for it)
My site http://www.codeabbey.com was created as collection of practical exercises - more advanced of them go along with theory description (e.g. data compression, encryption, math algorithms etc). Besides texts you can also learn from other's solutions there in different languages.
However I'm not sure you meant this exactly as you told about too diverse set of languages.
You should learn to generate ideas on your own! However you can find some project ideas at Karan Projects or some interactively checked exercises at CodeAbbey, CodingBat and other resources mentioned in the FAQ
The reason they use the term "standard input" is because the site is language agnostic. You can use a keyboard input, or read from a file. You should read this: http://www.codeabbey.com/index/wiki/solving For each line in the input data you will need to an input prompt. If you can't quite get the second line into something useful let me know and I'll post the first two lines from my solution and it should be clear.
I'm 8 months in. I started on Codeacademy for Python, and finished it after about a month. The realization I hit when I finished, though, is that I only had the syntax, but I couldn't actually do anything with it. It was like knowing every preposition in English, fifty nouns, and nothing else.
So finish Codecademy. It's good for the syntax, and for keeping you going. Every day you try doing an exercise, though, also try an exercise from here. It's very simple math, I/O, and string processing. The biggest thing I learned from programming is that almost any fucking thing can be brought down to string processing, lists, and integers. Once you solve a problem, look at some of the other peoples' answers. Some of them are really stupid. Some are reductive. But some people use really smart solutions that other people thought up first, and make it work for them. Because that's what you need, when you're programming- a combination of really smart paradigms, tailor-made for your own situation. And pretty soon you'll be thinking of how to solve problems and make things actively.
E: Whoops, put in the wrong site.
> We focused on scanners, I/O,
You may try solving problems at my site:
Though you will not usually need GUI for these exercises and no one will care if you use OOP or not. But you can compare your solutions with ones submitted by other users and learn from them...
Not too bad, but you should try to split your "main" method into several smaller. Currently it is quite unhandy.
You see, all other methods are about 10 lines - this is a good measure.
Gameplay looks strange to me:
First card: king of diamonds Second card: queen of spades Those 2 cards add up to a value of 20
Do you want to draw another card? n Whoops! You went bust!
Another thing - probably it is better to use 2-characters designations for cards rather their full names. Like in last example at this page.
Then you will be able to show the whole hand in a single line which would be more readable. You can even write total in the same line:
your hand: s9 + dA + c3 = 13
And the last thing - if you do not mind falling back to Python 2, then you can use this nice tool:
It allows you to save your small programs and easily demonstrate them to others "in live mode". Though it is clumsy enough...
I readily upvote this! K&R are my favorite for C!
I had learnt C by this book expecially thanks to their exercises.
But make sure you lay your hands on the latest revision.
Also make sure you do not mistake C for C++ :)
And at last - you may find some programming exercises (not specific to any language) at my small site for beginners.
My personal experience is to invent problems for yourself and then try to solve them (not critical if you invent a problem which you could not solve at all).
I suspect that it is most crucial for real developer - to be able not only solve tasks but also have some skills in finding or creating them - though it may sould bit controversial at first... :)
If you really-really have too few ideas of your own, you may try solving problems on different topics at some site with programming exercises and try to modify problems here to your own tastes.
For example here is a small exercise on data compression at my site - and after solving it hypotetical user can try creating a standalone utility for compressing texts and try to measure how well (or poorly) it performs etc.
So, concluding, it is important to teach your brain to be in perpetual motion - it will necessarily bring forth some proper fruits. :)
> Programming isn't my passion. I was formerly a music major, but I don't like being a musician all that much and I want a job with better financial stability
Beware here - it is quite popular misunderstanding. You usually need some degree of "passion" to programming to be successful in it. You surely do not want spend your life overworking on low-paid positions in some unworthy companies - do you?
Though probably it is just the same with almost any field.
> Any general advice you have
Just have a lot of practice in anything you feel interesting. You use C#? Practice it. You want learn Unity - practice it! You want write games? Try writing games, starting from simplest.
> Other skills besides "learn a language" that I should work on (like math, plan is to work my way through some Kahn Academy late algebra + calculus (+ trig?))
I do not think you'll need calculus and trig much. For general developer you'd prefer sane experience with sql, svn and git etc. instead.
Of course you should have fluence in solving practical programming tasks.
> Advice for fitting in/not feeling like an imposter/not losing motivation/not feeling discouraged
Try to work on "your own great project". I myself started the site with problems for beginner programmers mainly because I was bored by my job. And it really feels like a Tamagochi, ha-ha!
CodeAbbey - Not as big as Euler project yet I found it very good. You can submit answer in different programming languages http://www.codeabbey.com/
Checkio - Resolve programming problems in form of a game https://checkio.org/. I found that best part is that you can look at other people solutions to see how you can improve your code. Of course once you solve it yourself!
Console.ReadLine() returns a string from the standard input (which will be fed to your program if you use one of the buttons in the bottom right of CodeAbbey). Then you need to split the line into two strings, and then parse them into an integer.
Assuming you've solved the very first problem, you can see other people's solutions. Here's one that demonstrates what I'm talking about: http://www.codeabbey.com/index/task_solution?task=sum-of-two&user=chintanshah&lang=C%23
Here's what worked for me:
I found that Code Abbey doesn't hold your hand, you can also code solutions in any language you want, with the exception of a few problems. The problems introduce you to concepts such as sort algorithms, various searches, encryption, big-o notation, and data structures which you would learn in a typical intro CS course. While this site doesn't teach you language syntax, it's a means to test your knowledge and push you in a direction of higher level concepts. So I'd recommend starting here after you have read through the docs of your language of choice or took a codeacademy lesson.
The same goes for r/dailyprogrammer except that it's lacking any structure, but still a great place to find challenging problems to solve. A real benefit from both sites is you can look at others solutions (for codeabbey however only after you solve the problem) and you may get feed back and suggestions on your code.
> I think you mistyped CodeAcademy
For the reason unknown to me they do not have this "A" at beginning of "cademy" :)
> You said you mainly use Java, did you learn Java from internet resources?
In short - I was solving problems from http://codeforces.com constantly reading java language reference and java API documentation - as well as googled for examples about specific questions. It was not the easy matter (both codeforces and java). This article have more details:
http://www.codeabbey.com/index/wiki/long-road-of-learning-java
I believe you can find many interesting links in the FAQ. There are lists like this.
Or just google for articles like this: Finished Codecademy - what next?
At CodeAbbey you can see others' solutions, though after you solved problem yourself. Python is the most popular language there so you'll have a lot of material to learn. I recommend browsing solutions of top-rated guys of course...
> Are there any beginner challenges to help me get better at Python?
> I've done some various things to get started, looking to take it to the next level.
I believe you'll find there more advanced exercises / challenges - and some of them of practical importance.
There is http://codingbat.com dedicated specifically to Java (and also Python).
If you rather search for general exercise, perhaps my http://www.codeabbey.com may suit you. After solving each exercise you can browse other's codes to learn from them. This usually is almost as good as if those people teach you personally... :)
Not sure if it could be helpful... My site http://www.codeabbey.com has the same purpose but with somewhat differing ideology.
It offers you a set of programming problems, starting from easiest. It is supposed you already know basics of some programming language (e.g. after CodeCademy). Solving these exercises you learn some algorithmic things, get general practice and also can see how other people solve the same problems in your chosen language. Btw after 125 exercises you can ask for free certificate :)
Besides this note that interesting course based on Python is starting soon at Coursera:
It is <strong>Hunt the Wumpus</strong> for sure. I do not know whether you will easily find an online version, but it also exists in packages like bsdgames.
They use either random graph (maze) or, more historic, the graph built upon the edges of dodecahedron (how is it called in English?)
Playing even the version with 20 nodes (usually 3 outgoing edges from each) is not quite easy deal as one feel need to take pencil and paper and try to make notes and try guesses on what is the structure of the maze is.
You also can take efforts and prepare board version, to be played without computer, of course. Just create several small random maps (in form of transition tables and marks for bats and wumpus)...
Besides I have interactive programming puzzle based on this game in my collection: Maze of the Wumpus
As about something else it seems like the problem of finding chain of friends between two people (not obviously related) in facebook is just the kind of the task. We see nearest neighborhood, but have no idea of the further connections until we traverse these neighbor pages. I have another exercise Social Web Scrapper which logically represents scanning the graph in this manner.
> How hard is it to implement facial recognition?
That is usually far above the skills of one who learns "basics". The best metric of how ready you are is that if you have completely no idea where to start (or where to google) - then you probably should try something easier.
> What programming language?
Any contemporary mainstream language will do
> How would I need to start
Probably with outlining more details about your project - e.g. whether you are going to "scrape" the facebook pages or fill the data manually. I recollect one simple exercise on the web-scraping which may get you introduced to the idea.
The main problem is that usually there are not as many people willing to dedicate their free time on reviewing beginner's code and writing feedback :)
However you still can achieve something like this using forums etc. For example if you solve the problem at http://www.codeabbey.com you can then create a post at the forum there and ask certain question about your solution (it becomes visible to other participants who already solved the same problem).
Though of course you should avoid abusing people for example by repeating your mistakes. E.g. if you are told once that your coding style is very poor, it is bad idea to tell "but I do it for myself" and then ask opinions about another code which is also poorly styled and you have no intention to improve it.
Check out /r/learnprogramming and /r/dailyprogrammer. They have quite a few good resources.
One of my personal favorites for challenges is http://www.codeabbey.com/. Work at those and once you've solved one your way, look at how others have solved it and see what you could do differently.
1.) For a complete beginner, don't worry about Github right now. Github is a way of organizing your source files when working with multiple people. It isn't hard to get a grasp of, I just don't see a point in using it at your stage. To figure out how to practice what you've learned, go take a shower and think to yourself. Think of tools you can create on your computer that can make the task easier. Think about simple games you can make, or even a game solver (soduko for example).
This side was really fun. The site has multiple math problems that you solve using any language you want. Check it out.
2.) To make money off of this without making it a career, I suggest making your own phone app that people would use. Maybe check out elance and check under programming jobs to see what work people want done.
> I've been having a lot of fun with Project Euler.
CodeAbbey could be useful in similar way - moreover that one can see other's solutions here (after solving) - and many of them are in Python...
I'm not sure what level of exercises you are speaking of, but perhaps you may find my site useful http://www.codeabbey.com
I'm trying to gather there exercises allowing "smooth" learning curve - and besides after solving each of them you can browse other's solutions if you suspect you may learn a bit from them. I believe you can solve at least few dozens exercises before next Monday... You are right in that you started to care about preparation before it is too late :)
Actually you can organize "ifs" in BF easily enough (a kind of one-shot loops). However writing FizzBuzz in BF is rather boring exercise - rather of toil than of any interest.
Any program in any language can use pre-condition loops instead of "ifs":
if (something) { doSomething(); }
while (something) { doSomething(); break; // or something = false; }
You can find few more suitable BF exercises here:
http://www.codeabbey.com/index/task_list/brainfuck
Feel free to visit my site http://www.codeabbey.com which was built with exactly this purpose - to offer practical tasks starting from simplest. :)
> it's the same with all my friends
offer them a competition - who will be first to reach some level there (e.g. solving 25 problems - or perhaps solving 125 and securing "certificate")... this may help in keeping motivation...
I would also be inerested in this. So far the only thing I've come across is this: http://www.codeabbey.com/
edit: oh and I had this bookmarked http://www.reddit.com/r/learnprogramming/comments/2a9ygh/1000_beginner_programming_projects_xpost/
Wow, here are that many info about implementing scrapers! I'll remember this page.
Meanwhile I instead drop here link to "exercise" on scraping for beginners:
http://www.codeabbey.com/index/task_view/social-web-scraper
It provides "dummy" web-site to scrape so that one can conduct experiments without abusing some real site or network.
Have you any chance to try some other book?
If you have the least programming experience, then any of Cay Horstmann's books on Java should make you more comfortable.
Also try exercises at http://codingbat.com - they are interactive and specially created for learning java.
> I can easily create a PLU to solve an issue but when it comes to breaking that down to the step by step implementation
This is a separate issue - you just need practice-and-practice-and-practice and in a month or two you'll feel yourself more confident. You may try visit my site and solve problems starting from simplest, then comparing your solutions with other people codes in java. You know it is like analyzing chess game after it is played - good way to learn from your and others' mistakes :)
You may try these problems and exercises either in order, or randomly. If you solve some, you will be able to see other people's solutions (and filter them by Java language if you need).
Also note a list of resources in FAQ. And by the way there is nice interactive resource for java-beginners: http://codingbat.com
Or did you mean some larger-scale projects - those which can take from week to month to complete? Like small web-apps (well, in java small web-app may consist of several dozens of files). I think I can recollect something of the kind if you need this...
> I didn't really think there was a thing like too long methods though, as long as they basically perform one function.
Well, I know maniacs in industrial development who insist methods should not be longer than 7 lines. The author of the book I've mentioned is one of them. :)
Most people would be content if you do not exceed 15-20 lines (so that it is easy to cover the method with one glance).
Surely it can perform one function, but if it is rather long then probably it includes too low-level code which should be put in separate method and called from there.
What is more serious behind this - the concepts of testability and maintainability of your code. Shortly speaking long methods affect these abstract parameters :(
> BTW, I'm doing primarily Python now
Regretfully. If you will decide to go java way, you may have a peek at the article I wrote for my company and later translated here. Shortly speaking it is about how I struggled to switch from C to Java with some useful abbreviations and perhaps links. :)
With Python take care of learning at least a bit about django and unit-testing packages (which are provided with standard libraries if I remember correctly)
Probably not precisely a walkthrough, but it is my own java-story:
If you want more elaborate answer, you probably need to explain what is your current level in programming and what goals you are after (i.e. learning Java for university or for work etc.)
> I have Eclipse to start coding and I was looking through YouTube
Yes, I'm afraid watching videos does not help much. Java is a bit tough and practice-books-documentation is better recipe...
Well, you may try any of the sites mentioned in FAQ (and my http://www.codeabbey.com among them). Usually there are exercises but not solutions and explanations. However with most of them you will be able to progress on your own, learninig how to solve next problems from previous (and rarely asking questions here or somewhere else).
> our class has been working mainly wih pascal compilers but I got ahead of the others
I'm afraid that you should try to master at least one more contemporary language - like Python or, perhaps C++ or Java (which are more preferable for programming competitions).
Pascal usually lacks many advanced built-in algorithms and data structures so you will have hard time if you use it for programming competitions.
By the way, what exactly competition you are speaking about?
It is about "public key cryptography" when one key is only useful for encryption and another only for decryption.
I have several small exercises at my site which may give you the idea how these methods work:
Hope they may help!
For me my favorite "tamagochi" is my site with programming problems:
It is not the most complex / complicated thing I ever wrote, but it gives me much joy, moreover that before publishing some new problem I need to invent and solve it myself, probably also building some demo or infrastructure...
I also feel very cool when (perhaps, many years ago) I wrote my first 3D-maze or game with "soma cubes" with OpenGL - but it was different because they never went to state of continuous development...
I also have found that some solutions which I brute-forced at ProjectEuler allow more wise approach.
Here is an example of the task Pythagorean Triples which could be easily brute-forced on ProjectEuler, but I created another version of it to make brute-forcing difficult. ha-ha!
> both on reddit and on hacker news, say that after the first 15-50 challenges
I solved about 40 and could not say it is exactly so. However another problem is that some tasks resembles other in style of solving (e.g. bruteforcing over list of primes etc.).
I can think of three resources vaguely resembling "list of 100 problems":
http://rosettacode.org/wiki/Rosetta_Code - a number of popular problems solved in many languages
99 Python Problems - popular list translated for several languages (lisp, prolog etc.)
http://www.codeabbey.com - a set of basic programming problems - but it is not wiki, it is more like ProjectEuler you have already discussed...
Hi! Thanks for feedback!
I'm not quite sure what is "drum up" in relation to assignments - I'm sorry for my poor knowledge of English - but if I understood you correctly it would be very cool! Of course no code is needed, I anyway need to solve any problem I add myself and then create a "checker" for it :)
You can use any convenient way from Contacts and Support to reach me!
Project Euler is very math-focused. You should be able to solve a lot of them without much trouble, but some are very difficult without knowing a specific mathematical principle or theorem. So don't be too worried about it if you're just trying to get some programming practice.
I've also seen this site posted here. It might be more in line with what you're looking for: http://www.codeabbey.com/
There is a resource for learning java basics: http://codingbat.com
Or you can visit my own site with small problems for practicing:
After solving each problem you will be able to check others' solutions - I recommend ones of atom_man user - he is in tops and he is writing in Java
- so studying and comparing sources would be good help for learner.
Shortly concluding you need tons of practice (believe, we all also were beginners) - exercises, writing, solving etc... And of course some books, free courses etc should not be ignored.
>The problem is when I get to something I don't understand fast enough and is very difficult I just look at the time and quit once I'm past the 50 minute mark. This results in multiple days where I do spend the 50 minuts and reach my goal every day, but it leaves me dissapointed and kind of ruins my day because I still feel like a failure. This keeps going on for multiple days until I understand the difficult part and can move on. Then I'm there again spendig multiple hours working on my skill.
I know exactly how you feel, and I've been there (and I'm still there). I'm currently going through the exercism and codeabbey problems, and I try to solve one problem a day. Once I got to the harder problems, that started to be more and more difficult to maintain, and I became consumed by the problem to the point that it started taking away time from my other items of the day.
Here's what worked for me on the problems that made me stuck. Use pen and paper. Try to visualize your program somehow. Draw things out. George Polya once said: "“If you can't solve a problem, then there is an easier problem you can solve: find it.” As a measure of last last resort, Google (tangential) questions and add "quora" or "stackoverflow" at the end, and see some helpful answers. Don't try to reinvent the wheel, there are plenty of things to develop on with your creativity. One last thing, at the end of your 50 minute session, if you reached to a place that you don't understand, don't throw everything away. If you wrote a piece of code that didn't exactly work, keep it. Keep all your pen and paper notes as well for the next day. Take advantage of the effort you spent yesterday in today's 50 minutes so that you don't end up re-understanding the problem everytime.
Best of luck!
Awesome work. The mere fact that you maintained/kept track of your success/failure is a success in and of itself. :)
>It's been not so bad so far, but I'd really like to add some quality to the work I do. Keep the bar low so that maintaining the habit always remains easy, and add quality after you've comfortably crossed off all the habits of the day. I have been seriously working on habit building for the past ~667 days, and for some reason things work out great in the beginning until I choose to increase the intensity of the habit, and then things turn to shit on some days where schedule really doesn't permit me to maintain that habit, and it just snowballs from there.
What did work for me is to keep that bar low enough to maintain, but high enough to do some quality work by accumulative effort. If I wanted to do more than what the low bar requires, I'll do it if the schedule of the day permits it. If not, then at least I maintained my streak and don't feel like shit.
Try Habitica. I've been using it for the past 2 years and it's been helping me with keeping track of habit building.
>CS > Programming > Eat Fruits I have a programming daily habit as well! I'm currently working on the codeabbey problems, working my way through it one (at least) problem a day. If you're interested and would like an accountability partner, pm me.
So in the page you linked, it looks like the problem just requires you to compute the code table. The "homework" section takes it a bit further and asks you to actually write a compressor. I'm not sure if you're trying to just do the assignment or if you want to go further and write a working compressor.
Note that, since this is still a variable coding, you'll need to aggregate bit strings into bytes before writing them. A previous problem covers this.
On disk, all files are inherently sequences of bytes. ASCII-encoded text files are just files whose byte values are all less than 128. There are other ways to encode text: UTF-8 and UTF-16 are both ways to encode unicode characters.
To actually write the bytes to disk, you'll need to figure out how to write binary data to a file in Python. Many languages let you say, when opening a file, whether you intend to write text or binary data.
Depends on many things.
/r/learnprogramming is a good starting place and the place to go when you need some help.
There are also some places where you can get language specific help (e.g /r/learnpython) {also python is a beginner programming friendy language and the one I recommend}
If you choose to start with python, look at this.
For some problems to start practicing I'd recommend this
Forgot to link to the Problem Link: http://www.codeabbey.com/index/task_view/maze-of-the-wumpus
@GroggyOtter: Yes and no. CodeAbbey asks that you not show your work on other sites but it's available for review by anyone who has solved the problem. So if you want see it, solve it, then we can compare notes!
http://www.codeabbey.com/index/task_list this is what I have done... a long time ago, with python then java then javascript. It is very well made, and you can see other people's answer after each test, and trust me, you will go "awwww that's how it's done! "
> If you are into mathematics
And if you are not, then CodeAbbey is, probably, better idea. It is built after the manner of ProjectEuler, but collects programming problems, not mathy.
If you rather want some larger projects, not small exercises - it is worth to search for ideas lists like this one.
> Could anyone recommend me free resources and or books that are friendly to biologists?
Beware here! Coursera really has several courses on bioinformatics - and they have even collection of exercises at http://rosalind.info - however I'm not sure it is really simple stuff for biologist.
If you'll find them bit too hard, I can also propose http://www.codeabbey.com for a change.
And also it may be worth to browse these exercises - about Huffman and other variable-length codes, about sliding-window approach and entropy:
These are usually general-purpose programs, not something web-related. However I dare to suggest another resource of similar kind: http://www.codeabbey.com - here people can solve programming problems and then browse others' solutions. There were several hundreds people writing in JS - and some of them surely were quite advanced...
As a Java programmer I dare say it is not the best idea start learning programming with Java. The language is purposely more complicated compared to some others.
However, the choice is up to you. Here are a couple of my articles:
My long road to Java - rather long, about how I started learning java (already working as programmer) - where to get practice, what to read, what steps to take...
Most popular language among beginners (why it is Python) - for I believe it will be good to spend a month or two on Python before approaching Java.
> Is that a good idea
Yes it is a nice course for beginner. They use specific implementation of Python in javascript so you can run it directly in browser (though it corresponds to Python 2.6 if I am correct).
I helped a couple of colleagues to get through this course. Though I confess it feels bit slow/dull when you get a bit advanced. So it is a true course for beginner.
> and if so, is there another course that would be good to take simultaneously
I believe you will have enough courses (adding your codecademy experience) - though of course you can get another from EdX if you really want to...
https://www.edx.org/course/introduction-computer-science-mitx-6-00-1x7
https://www.edx.org/course/learn-program-using-python-utarlingtonx-cse1309x
the first of them is bit harder I believe...
But usually you learn language just by writing code exercises, like problems from my site http://www.codeabbey.com - here you can also see other's solutions after solving yourself (some are very valuable to learn from) - and Python is most popular language here, by the way... Sorry for a bit advertising :)
> Also would it be recommended to try for a certificate from these classes if they are offered?
You will get free "statement of accomplishment" from them (if you will get through the course). Optional "verified certificates" - I'm afraid it is not the thing to care about, at least for this course. Paying for certificate about completing beginner's course even may look ridiculous to your potential employer etc...
(BTW you can also get certificate (free) at the site mentioned above for solving 125 problems - oh, sorry again, ha-ha)
Problem is not very confusing, it is just vaguely expressed. In statistics they call it something like "throwing away outlier data points" (which may be caused by some critical errors in measurement equipment for example).
As they ask only to throw away one copy (which is bit strange), I think you can do the following trick:
N-2
I also think you'd better find min and max of the data in a separate function. E.g. you should have a merge of two problems, one like Max and Min of Array and another like Average of Array
I'm trying to collect beginner's exercises at my site:
http://www.codeabbey.com/index/task_list
so that it is possible to work from the easiest to harder and harder... Many site's users do them in Python so it is possible to learn by solving yourself and then peeking into others' sources. Winning a certificate requires 125 solutions - this is just a kind of motivation...
Other than that you can be interested in online courses - either at coursera or, perhaps even best, at EdX, e.g.:
https://www.edx.org/course/learn-program-using-python-utarlingtonx-cse1309x
https://www.edx.org/course/introduction-computer-science-mitx-6-00-1x7
Of course nothing can substitute learning from documentation, so do not forget to read official python docs on things you are using (standard methods etc.) - this will make your knowledge far more solid.
That would be because you need to take the numbers as input. Right now you're writing the input by hand, but the input will change once you submit the program. I think anyway, never used code abbey.
But take a look at the Java section here http://www.codeabbey.com/index/wiki/running.
You need to make a loop in order to record all of the input and that's it, the second half of your program functions as it should.
Browse problems at CodeAbbey - probably will not be interested with simpler ones, but those which are harder may give you ideas of games or tools, or even extend your overall CS knowledge.
Music - that is great. Then I would be twice glad if you find my site useful. I already know some of people there who are teachers, who are musicians and even one who is really music teacher (profile here, but without autobiography) :)
Meanwhile I myself sometimes tell my friends that I'm going to quit programming job and go to play music in the streets (and coding at home as a hobby) - well, this is more of a joke still...
I'm not sure I get well where are you right now. Have a look at my article Long Road to Java - beware, article itself is bit too long :)
You may keep on writing small practical projects (like these on the same site) if you do not feel confident with what you have learned. Otherwise you should move to Java EE / web. Write some simple web-application, learn servlets, JSP etc. for example this - or one mentioned in the appendix to the article above.
(excuse me for a kind of PR - but I believe you will not complain links are completely useless)
In a sense, it is, yes.
However, you should note that there's a fair bit of programming that is mathematical. Programming is a subset of CS, which is a math heavy field. Algorithms, in particular, are extremely "mathy".
As you may have already found out, the algorithm affects performance drastically. I cannot understand how incredibly important the algorithm can be. For some problems, the difference between an efficient algorithm and a brute force solution is a literal life time. Yes, I mean 80 years of run time. I'm not exaggerating.
All that said, it's not necessarily the best source of exercises for an early beginner. CodeAbbey may be a better choice. When you're feeling up to it, you should attempt to create a project of your own, building an idea into something larger (which you can also use as an opportunity to learn useful tools like version control, build tools, dependency management, etc).
I started not long ago as well, and I found the problems at CodeAbbey to be a great next step after getting the basics from Codecademy.
The CodeAbbey problems start really simple, and progressively get more difficult. And once you solve a problem, you can see other people's solutions to the same problem, which is also really helpful I've found.
I would pick a language (Python is solid) and stick with it for awhile, start solving problems with it, so you can learn to actually program, rather than simply learning the syntax of particular language(s).
http://www.codeabbey.com/ this is where i started doing my own stuff. i am still learning myself. i can totally relate to not having something that both fills my interest and provides a stepping stone to go into something new. i am playing with making a card game program that i can run different games using the same common classes. but i want to learn how to do web crawlers and stuff like that but every time i see a tutorial it all seems just a bit out of my reach.
I suggest that you keep practicing the language by doing exercises. That's what I am doing right now after I finished the book "Learn Python the Hard Way".
These sites provides exercises.
EDIT: Fixed formatting
> lots of practice and writing code code
I second this! Go solving problems at http://www.codeabbey.com or https://projecteuler.net for example - and compare your solutions with ones of people who seem to know the chosen language better. Learning from other's small (!) codes may give many good ideas especially at beginning.
Though the main idea is to store your code here, you may find other usages:
http://www.codeabbey.com/index/wiki/github
> But I'm wondering what the standards are for the code to be on there.
No, they mainly rely on standards for specific language. I.e. if it is java-project - the best way is to store it in maven-based style etc.
> why are there multiple folders within each person's "repository"?
Either because the project in this repo consists of several folders, or because person stores multiple projects in a single repo (this may be ok if they are very small education projects and one is too lazy to create separate repo for each of them).
I recently have seen at forum some short story of an officer (navy?) now going to Master in CS. I have no idea whether this may help, but probably you can get from it more than I (or even contact him for more details):
(note his linkedin profile by the reference from his post - to get idea of his military career)
> The modular calculator #14 is giving me trouble as i was using long long, but I'll revisit using double.
This does not require neither long long, nor double. Probably this thread can explain more:
http://www.codeabbey.com/index/forum_topic/a568c45c675d4f24c727fd230bdc3449
P.S. Thank you for your kind words. Anyway the site could never be good without such a kind users and their feedback and ideas! :)
> Where can I start to learn how to solve problems like this as the only language I really know at the moment is C++
I hope my small site can help you. There are enough people solving in C++ (you'll see yourself) and you'll be able to compare your solutions with theirs to learn better.
Feel free to skip those problems which you think are very easy or very hard to you. You can always return to them (and to /r/dailyprogrammer) later... :)