ForumTechnical Corner ► Codin and stuff
Coders of Two Cans, how did you get into it?
(Same goes for hackers, Btw)

Also would you recommend any books or classes? I'm currently in HS and taking a coding class next semester, should I do anything to prepare for it?

Cheers! -Samsung23
  
It depends on the class, but if it's a beginner's class all you need to know is absolutely nothing.

If it's an intermediate class or something else though, a familiarity with boolean logic and algebra is a strong foundation.
  
Kylljoy said:
It depends on the class, but if it's a beginner's class all you need to know is absolutely nothing.

If it's an intermediate class or something else though, a familiarity with boolean logic and algebra is a strong foundation.


Boolean?
  
Boolean logic means like:

If A or (B and C), then (do something).

Where A, B, and C can either be true or false. You likely are not expected to know it for your class, and you'll pick it up quick.
  
Oh so like:

if True;
print ("This is true")
else:
print ("I did something wrong")
  
Yeah, I think so.

There are comparisons as well, so like:

test = 9 + 4

if test < 5:
print("This will not print")
else: 
print("This should print")
  
Thnx!
  
The book below was my first foray into coding alongside a class that was an intro to coding class at my local community college that I took over a summer instead taking the intro class at my actual university. I thought it was pretty simple and straightforward, if a bit too easy. The rest of my coding classes were in c++ so taking this instead of the usual intro (which was in Python), made my college classes easier even though I never learned Python.

Starting Out with C++: From Control Structures through Objects, Brief Edition (7th Edition)
  
Learning python 3, but I'm starting to wonder if it is even worth it. I am wanting to make a online choose your own adventure book type thing, but I don't know if you have to have python installed manually on most computer or if you can load it directly from a web page.
  
Python isn't super-well suited for running from a web page in its default form, no.

Ren'py https://www.renpy.org/ is built for making visual novels, but I'm sure you can produce just CYOA games as well.

Twine (https://twinery.org/) is built for this, but has its own scripting language that you will need to learn.

Both of these can publish to a webpage so people can play from their browsers.
  
Alternately, mayhaps Crayon?
  
Kind of sounds like you want Brython. It's a Browser implementation of Python such that Python runs in an HTML page the same way JavaScript would.
  
Started programming a really long time ago but never really got the hang of it. I spent 4 years on scratch doing nothing except playing with lego code blocks, i eventually snapped out of it. Javascript's nice. paid 18 dollars for a 60 hour course on it... hopefully that goes well...

if there are any JS programmers on here... do you prefer function declarations or function expressions? and how often do you use strict mode?
  
I use fat arrow functions instead of function expressions unless I explicitly need the behavior of `arguments` or `this` that's associated with function expressions. And so usually if I see a `function` keyword used in my own code, I can safely assume there's a specific reason why. Function declarations (with the name after the `function` keyword) I only use if I need to use it as a constructor.

This is just my own preference since I'm pretty big on making sure code always exhibits original intent and this is the specific convention I choose to use.

Use strict mode always.
  
Forum > Technical Corner > Codin and stuff