Created
June 17, 2021 16:03
-
-
Save abuxton/f9ec8c3efd2584ea18cead38c1d752fd to your computer and use it in GitHub Desktop.
learn any language primer
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
1. Syntax - The syntax of a language describes the structure of code. This encompasses both how the code is written on a line-by-line basis as well as the actual words used to construct code statements.A language's syntax also involves things like including libraries, setting variables, and terminating lines. With practice, you'll learn to recognize syntactical requirements (and conventions) almost subliminally as you read sample code. | |
2. Built-ins and conditionals - A programming language, just like a natural language, has a finite number of words it recognizes as valid. This vocabulary can be expanded with additional libraries, but the core language knows a specific set of keywords. Knowing these keywords gives you the ability to write basic expressions, the building blocks of a program. | |
3. Data types - Code deals with data, so you must learn how a programming language recognizes different kinds of data. All languages understand integers and most understand decimals and individual characters (a, b, c, and so on), but sometimes a language has extra data types built into it, and other times complex data types are enabled with libraries. For instance, Python recognizes a string of characters with the keyword str. | |
4. Operators and parsers - Once you understand the types of data a programming language deals in, you can learn how to analyze that data. Luckily, the discipline of mathematics is pretty stable, so math operators are often the same (or at least very similar) across many languages. | |
5. Functions - While flow control with conditional statements and math and logic operators can do a lot, code is a lot more efficient once functions and classes are introduced because they let you define subroutines. | |
x: figure out if there is a object method in teh language executor such as ruby module helper or go parser | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment