Getting back into coding

Curll

Guest
Jul 13, 2005
9,205
I haven't really touched any code in ~10 years, aside from the occasional Wordpress hack.
 
I hoped on CodeAcademy and starting playing with Ruby (I'm on, like, lesson 3). 
 
I'm just looking to play around with modern code and build a simple web app or a mobile/web app hybrid. Nothing fancy or commercial, just want to get back into building stuff.
 
Is Ruby the best for this, should I poke around with Python? Are there better places than CodeAcademy?
 

rembrat

Member
SoSH Member
May 26, 2006
36,345
Ruby should serve just fine. 
 
Aside from CodeAcademy I would highly recommend a video tutorial site. https://tutsplus.com/courses/?q=true&filter_topic=35
 
Tutsplus has a bunch of video and article resources in a host of different programming languages. It's mainly geared towards web developers. There is also stuff on modern workflow and tools of the day. You also get access to free e-books. I think I signed up during a promotional sale for $130? for the year. It might be different now but it's worth it considering the vast amount of information available to you.
 
The videos are easy to follow (plus downloadable) and you can watch the instructor code as he lectures. 
 

SumnerH

Malt Liquor Picker
Dope
SoSH Member
Jul 18, 2005
31,888
Alexandria, VA
I prefer Python, but Ruby is fine.  I haven't used Code Academy before, but going through the first few pages it looks pretty mind-numbing.  In general, books and static pages are much easier (and faster) to learn from than videos and interactive tutorials, IMO, especially for someone who's getting back into coding rather than learning from nothing--you can quickly skip boilerplate or stuff you already know, and easily re-read anything you didn't grasp the first time.  And watching someone else writing code tends to be distracting as you focus on their editor, typing skills, approach to writing, etc rather than learning the core concepts.
 
I'd definitely recommend learning the language  (whatever it is) first for standalone apps before trying to write web apps--debugging the latter is a whole extra level of pain and complication that's much easier if you're already comfortable with the language before you start it.
 
For Python I recommend Learn Python the Hard Way.  I haven't used it before, but the Ruby equivalent gets good reviews.
 

repole

New Member
Dec 16, 2005
189
Charlotte, NC
Ruby's a quality choice, though count me in the group that prefers Python. Micro frameworks like Flask and CherryPy make it easy to get started (similar to Sinatra with Ruby), while Django (similar to Rails) gives you all the bells and whistles but has a bit more overhead with getting started.
 
You'll use the same concepts with either, I'd suggest playing around with each language a bit, and getting a feel for which you might prefer.
 
Jul 10, 2002
4,279
Behind
Python and/or Ruby are that heavily used these days?  I'm curious.  And for what types of applications and businesses?  Meaning, if I'm at some, idk, fortune 500 company writing web-based CRUD apps -- Python and/or Ruby?
 

Blacken

Robespierre in a Cape
SoSH Member
Jul 24, 2007
12,152
TBH, I'd go with something with static typing and a little more structure than either Ruby or Python. It has its downsides, and there is more friction in getting started (but you sound motivated enough that that's not a big issue), but I'd look at Java or C# as a starting point. The compiler can generally point out your typing mistakes and structural mistakes before you try to run your code, leaving you to deal with the more difficult errors of logic. Java and C# both also have vastly superior tools for debugging, which you will find yourself doing a lot of to address those errors of logic.

(I am biased, though--I wouldn't trust that a Python programmer tied his shoes correctly unless he had a unit test for it.)
 

Blacken

Robespierre in a Cape
SoSH Member
Jul 24, 2007
12,152
HillysLastWalk said:
Python and/or Ruby are that heavily used these days?  I'm curious.
"Heavily used" as in they're all over any Linux server a developer or sysadmin will ever touch, yes. Basic building blocks like Vagrant and Puppet/Chef are Ruby applications; Ansible is a Python application. Most of Ubuntu's custom stuff is written in Python, too.

Ruby has pretty significant traction for web applications in companies where everyone isn't wearing a blue tie or sitting in a low-walled cubicle; it's the go-to for many startup types (for reasons both good and bad). It has some application-level penetration in enterprisey places, but less than in systems/shell-script++ roles.
 
Meaning, if I'm at some, idk, fortune 500 company writing web-based CRUD apps -- Python and/or Ruby?
Newer companies tend to have more Python and Ruby in their application stack, with the usual scaling route being to move to the JVM for performance reasons over time (Twitter went from Ruby to a heavily leveraged Scala environment). Older companies tend towards Java Servlets (as distinct from more modern JVM technologies) or ASP.NET (because they enjoy hurting themselves and paying extra for the privilege).

Working at a Fortune 500 company as a developer sounds like a fair approximation of hell regardless of tooling, though.
 

SumnerH

Malt Liquor Picker
Dope
SoSH Member
Jul 18, 2005
31,888
Alexandria, VA
HillysLastWalk said:
Python and/or Ruby are that heavily used these days?  I'm curious.  And for what types of applications and businesses?  Meaning, if I'm at some, idk, fortune 500 company writing web-based CRUD apps -- Python and/or Ruby?
 
I've used Python at 2 Fortune 500 companies, though it tends to be on smaller projects; large institutions like that have vast amounts of momentum attached to large projects and don't readily adopt new technologies.
 
They tend to be pretty shitty places for a new programmer to work, anyway, so I wouldn't limit myself to what they're doing.
 
Pretty much every company I've worked at over the past 15+ years has used Python somewhere (from the aforementioned fortune 500s, to small startups, to big government bureaucracies.  
 
 
Blacken said:
TBH, I'd go with something with static typing and a little more structure than either Ruby or Python. It has its downsides, and there is more friction in getting started (but you sound motivated enough that that's not a big issue), but I'd look at Java or C# as a starting point.
 
To me those are okay languages for daily use, but they're not where I'd point someone who's learning to code.  My recommendation would be to progress through:
 
1. A simple dynamically typed language to get you going and see if you're actually interested in learning to code (Python, with an emphasis on OOP and a few glitzier UI/data presentation apps).  Learn your editor and environment without worrying much about the compiler, memory management, etc.
2. A low-level statically typed language with manual memory management (C, with an emphasis on structured programming and some close-to-the-iron device/memory management or at least bitmap twiddling or something).  Start working through Sedgewick and learning data structures and computational complexity.
3. A functional language (OCAML or Lisp, with a strong emphasis on functional programming and data transformation).  Start working through the dragon book learning parsing and lexing and intermediate representations.
 
If you do that well then you've come close to getting through sophomore year at MIT/CMU/Stanford/Berkeley in terms of knowledge*, which is enough to make you comfortable learning most languages (add in one assembly language, Forth, and Prolog and you're even closer) and give a decent underpinning to understand whatever's going on in the language and framework you wind up working on.
 
*On the software side only, not the intro hardware stuff
 
Jul 10, 2002
4,279
Behind
Agreed about Fortune 500 companies.  As a developer, a good rule of thumb to live by is to work for software companies.  Meaning, make sure you are the product and not supporting the product.
 
Personally, I'm not writing the next great software.  So I do like C# and Visual Studio.  And ASP.NET seems fine.  But the applications I write probably haven't pushed the boundaries that maybe apps you have written have.  So the hurting themselves comment is lost on me but probably true (in reference to Blacken's comment)
 

SumnerH

Malt Liquor Picker
Dope
SoSH Member
Jul 18, 2005
31,888
Alexandria, VA
Blacken said:
"Heavily used" as in they're all over any Linux server a developer or sysadmin will ever touch, yes. Basic building blocks like Vagrant and Puppet/Chef are Ruby applications; Ansible is a Python application. Most of Ubuntu's custom stuff is written in Python, too.

Ruby has pretty significant traction for web applications in companies where everyone isn't wearing a blue tie or sitting in a low-walled cubicle; it's the go-to for many startup types (for reasons both good and bad). It has some application-level penetration in enterprisey places, but less than in systems/shell-script++ roles.
 

Newer companies tend to have more Python and Ruby in their application stack, with the usual scaling route being to move to the JVM for performance reasons over time (Twitter went from Ruby to a heavily leveraged Scala environment). Older companies tend towards Java Servlets (as distinct from more modern JVM technologies) or ASP.NET (because they enjoy hurting themselves and paying extra for the privilege).
 
If you live in the DC area or anywhere else with a lot of government contractors, there's also a shocking amount of Ada code out there.  Even occasional Fortran.
 
I'm also occasionally surprised at the web places that have been around for a decade by the amount of leftover ColdFusion I still see.  Bleh.