How do i learn to program? HELP ME PLEASE :)

I would like to learn because it is fantastic and with this it can do everything that you want :slight_smile: but i do not know where i have to begin :frowning:
Please someone answer my question :slight_smile:
the goal of this website is learn people how to program,right? Help me to improve me :slight_smile:

2 Likes

I do not guarantee this is not the best approach, but I think you could start just trying to do the games. Python3 is probably the best language to learn, although opinions differ.

The first game is pretty easy but will push you to start coding. The basic code is already given to you and you have to complete it by translating a short “Pseudocode” explication from the instructions to the language you chose (e.g. Python3). You will have to use Google to find explanations (as we all do daily). Here, you may want to look for something like “python conditionals” (e.g. how to do something conditionally in Python).

You will most likely not get it from your first try. This is okay. This website is there for learning, which means failing. You can run test cases as many times as you want until you get it right.

Good luck!

3 Likes

Hi,

I do not know if starting with codingame with no pre knowledge is the best approach. It might end up very frustrating.

I am in a similar case than you. I started with online tutorials (a very complete one for Python in french, out of the website developpez.com - which i end up using for a school project). Such tutorials exists for most language for free around the web, i read one about c# more or less recently.

My advise would be to pick a language first (i heard a lot of ppl start with Python or Java), get a good tutorial with practical exercises (ideally based on a free IDE) (by tutorial i often mean “big” pdf documents 200 - 600 pages written by profs as online ressources gor their students). You usually dont need to do the whole tutorial at once. When it becomes too abstract, take a step back and exercises what you already learned.

This is where Codingame is very fun and useful. Itll “force you” to apply this theoritical knowledge, make you assimilate “fast” what you learned and maybe confront you to a concrete use case to the chapters you gave up reading due to “too abstracts” concepts. You can then go back to your tutorial and continue learning.

Its basically the iterative L&D “70-20-10” approach for self-study: 10% classroom learning (in this case, theoritical reading), 20% applied coaching (in this case, walkthrough exercises from the tutorial) and 70% learning by doing (codingame).

This seemd to work for me so far :wink:

@amin97mo : what is your mother tongue?

3 Likes

Prepare to spend a lot of time sucking and being terrible. That is like
 the first thing you should prepare for. “I’m
 going to be horrible at this for some time.”

Next step is: read. Read a fucking lot. Go to your library
 and read books on programming. A lot of the books will be terrible. You won’t be able to tell either, until you’ve read a lot of books. And you’ll need to have read terrible books to be able to know they are terrible. It is part of the process of knowing good books.

As you do this, practice with the games here.

Also practice with silly little programs. Make a compression scheme program that works by taking the first character out of a file and putting it into the file’s name (which
 TECHNICALLY shows up like it is compressed under some ways of measuring hard disc usage). Make another compression program that is major heavy lossy and just deletes everything over 1KiB in a file (A Lossy compression guaranteed to have the file shorter than 1KiB!)
 you won’t be able to decompress from the scheme though
 but yeah.

Program silly things, work on the games
 and read. Read some stuff that you just bring up around programmers to see if they know
 or if they decide you need medication. It can be hard to tell at times. As if you talk about RFC 2795 they will not be thinking you need medication.

It also requires a lot of work. You know, not like getting a puppy, where you gush about cute they are and claim you will walk them and then ignore it about a month later.

2 Likes

Go to a bookstore or library and look at what books they have.
Most books have a lot of example code in them that lets you play around and expriment with. Most of the easy games here can be done with only basic programming knowledge and skill.
Almost every bookstore in the world has at least one book on Java.
I’m not saying that Java is the best language , but it is easy to learn and very wel documented.
The choise of what language you use mostely has to do with what you want to do with it. If you want to get into web design , PHP will be a good choise , but for pc applications , java or C# will be a better choise.
If all you want to do is use it here , any of the supported languages will do , but i wouldn’t recommend Bash.

2 Likes

I support your lack of support for BASH.

People only program in BASH ironically. So freaking ironically so much of the ironing in that ironic BASH programming.

Have a look at the Codecademy Python course.
It won’t teach you program but it might give you a good idea of the fundamentals all languages have.

  • Variables
  • Loops
  • Arithmetic functions
  • Conditionals
  • Collections
    ETC
 (The basics we use everyday)

Then, when you choose a language and the books etc

You can build on the basics :smile:

1 Like

People only program in BASH ironically. So freaking ironically so much of the ironing in that ironic BASH programming.

Well, the power of bash comes from composability. Some specific problems are actually easier with it. That said, I conccur that you are better off with pretty much anything else (Python!).

1 Like

A lot of people are suggesting to start off with Python–and then possibly moving onto other languages
 that isn’t because Python is an inferior or inherently better language than all others.

There is strengths to being multilingual that any rather knowing programmer will be able to take skills from and do stuff with. Much like there are strengths to be multilingual with natural languages (People who defend only learning one language are freaking weird).

Typically the styles of languages that you’d be suggested to get a few (or at least one) in to better grok problems are:

  • Stack based language, Forth, Postscript
 I’m tempted to say Prolog–but I don’t know Prolog and I think I might be miscategorising it
  • C-esque
 this category tends to include C, Java, C++, Objective C, C# and others
 but it also tends to also end up having Algo-68, Pascal and Delphi (even though those barely fit there)
  • Line Noise (somebody give me a better name). Such as Perl or Bash/grep/awk or pdksh or tcsh or zsh
 though Intercal would qualify for this category–but uh
 go with Perl5/Perl6 for this category
  • Math Equation (there is a more correct name for this). Such as Haskell, F#, etc.
  • Grouping Orientated (there is a more correct name). Common Lisp, Clojure, etc.
  • Fungoid. Befunged and others based upon the whole Fungoid schemes
  • An Assembler. You probably should only learn one really well, I’d personally suggest 650*5x–but that is due to my own biases on the matter. You can kind of guess what others are doing based on knowing one really well
  • Python – this one does have a category, but it shares a category with COBOL
 and I cannot recommend COBOL. I can only recommend running as fast as you can away from COBOL
  • Templated language: PHP, RHTML, Mako, Jingo2, etc
  • A configuration language: Lua, Batch, XML, JSON, etc.
  • A “Basic”: take your pick, Dark Basic, GW Basic, Hypercard, qBasic, Amiga Basic, Visual Basic.Net
 this is mostly just so the people who learned on that don’t seem as weird to you. I mean
 they will still seem weird, but yeah.
  • A virtual machine “machine code”-- Parrot, JVM, CLI, etc. Honestly, these are really not that hard to learn (or at least JVM is) and it is nearly possible to write software programmed directly in the JVM machine code itself (with a bit of broiler plate code and something to pack all the files together).
  • Some form of Squirrel (I believe this one is called RDBM Relationship DataBase Manager): PostgreSQL (Elephant Squirrel), MySQL (MY SQUIRREL! MINE! MINE!), SQLite (Tiny Squirrel
 soooo smol!), Microsoft Access (this is a Squirrel, correct), Oracle (All seeing Squirrel), etc.

There are a lot of different types/styles of computer language. Knowing many of the different styles ultimately has you better able to use your preferred language in the long run.

I’ve also missed a few styles in this list–you know on top of giving them all quite incorrect names.

1 Like

I’m probably old school. But to be a good coder, you have to be good at math.

“but i won’t use math in my co
” be good at math i said
“but i don’t see the p
” BE GOOD AT MATH !!!

If you are good at math, you are a good coder. If you are a good coder, you are good at math.

Let’s clear this point : math and programming don’t share the same knowlegdes base, it’s obvious. In math you have to know formulas, theorem and everything like that. In programming you have to know basic algorithms, how to use loops, how to use every library you know, 


But the “way of thinking” is exactly the same.

  • Slice the problem into littles problems
  • Identify the first problem
  • Select the more adapted tool to resolve it
  • Use it
  • Repeat

If you want to know if a teenager will be a good coder, just look at his/her math results and grades.

Some colleagues also tells me that good math/coders are also good at music. But i can’t confirm that, i never tried :smiley:

Now if you want to start in programming, just select a language. But i’m old school too for that, so my advice is to never never ever never ever F*CKING ever never OH GOD NO PLZ DON’T DO THAT start with a non typed language. Start with wathever you want (C, C++, Java, Pascal, Ada, C# 
), but don’t start with a non typed language like javascript, python, ruby or php.

2 Likes

What? Python is a non typed language ? O_o

1 Like

Since you can do this :

a = "test"
a = 10

This is a non typed language. Python is like javascript, ruby and php, non-compiled, interpreted and non typed language.

(maybe “non typed” is not the exact word, i’m not very sure of the english word for that. In french we call that “non typĂ©â€)

1 Like

It’s a typed language but not a strongly typed language.
You can compile Python code in an executable via a dedicated library.
This kind of feature is useful for example when you have to test if a variable contains data or not, it’s the None type job.

1 Like

Ok so my advice is to avoid non strongly typed language when you want to start learning how to code. Just a vocabulary problem.

1 Like

I’m sure he understood what you meant and was just messing with you a little bit since you’re the almighty 1st :slight_smile:

2 Likes

I understand why you dislike non strongly typed languages but hard languages like C are to be avoided too because of its limitations.

C is fine to learn simple algorithms on integer and array like basic sorts. But yes C is pretty bad when you have to deal with strings. C++ is better for that. Pascal and Ada are pretty fine too.

I love Java but i think it is a little bad to start to learn programming because of the “all is pointer” behavior. C and C++ are good for this, you have to learn what is a pointer how it works.

I’m pretty sure that amin97mo didn’t grasp half of the information thrown here, because s/he’s a newbie. Trust my experience with my nieces, the only question to ask is: do you prefer [Frozen][1] or [Star Wars][2]? In fact, it’s a mostly pointless question, because Anna and Elsa are always picked over Rey.

Note: the book “Real World Haskell”, which happens to freely available, has an [enlighting chapter about typing][3]. Regarding Python, it is a (great) dynamically-typed language. Describing it as non-typed is typical of people who dislike ducks.

[1]: https://studio.code.org/s/frozen/stage/1/puzzle/1
  [2]: https://studio.code.org/s/starwarsblocks/stage/1/puzzle/1
  [3]: http://book.realworldhaskell.org/read/types-and-functions.html

1 Like

I’ve found the people better at learning new languages and art tend to be better at programming.

Math people tend to mostly be good at implementing previous solutions made (kind of
 not really).

If you have somebody who is multilingual, it generally allows them to view programming as explaining something to the computer. Which
 allows for some more interesting methodologies. With hacker things being treated mostly as language idioms and weirdness.

Which is why you cannot guess if a teenager will be good at something–as we don’t value multilingual capacities in modern day society. Even though people honestly should.

The viewing it as a language kind of gets around the language being strongly typed or not strongly typed
 and move more into “is this language awkward to talk to the computer with?”

Why do people keep using “a language can compile” as proof it is a typed language?

Most machine code is a non-typed language. In fact, the variables in Machine Code/Assembler tend to be ridiculously less strict about things than Ruby/Javascript/PHP

You want to use that object as one of the things you are going to use in a floating point division operation and create a string based upon the results? Assembler says, not even close to any kind of issue. Where even Ruby would look at you and go, “uh
 what
 the fuck
 are you
 seriously man
 the drugs aren’t working for you man
 they are working against you.”

1 Like