Coding Flashcards
Python interpreter
a program that can read Python programming statements and execute them
IDE
A graphical editor in which you can type code, work with multiple files, run code amongst other things.
.py
Used for executing programs
Output
The program giving something to the user
Pandas
Data analysis module for the Python programming language
Flask
Web frame work
Class
Template/blueprint that describes the behavior/state that the object of its type supports.
Byte
Byte data type is an 8-bit signed two’s complement integer
Short
Data type is a 16-bit signed two’s complement integer
Motion in Scratch is what color?
Blue
Looks is what color in Scratch?
Purple
The first sprite you get in a new scratch is a….
Cat
Can you have a sprite say things in Scratch?
Yes
Variables are what color?
Orange
When the sprite takes 10 steps, is that motion visable?
No
> > > knights = {‘gallahad’: ‘the pure’, ‘robin’: ‘the brave’}
for k, v in knights.items():
… print(k, v)
What method is this method?
The ( ) method
What function is this?
> > > for i, v in enumerate([‘tic’, ‘tac’, ‘toe’]):
The enumerate() function.
To loop over two or more sequences at the same time, you use this function.
The zip( ) function
To loop over a sequence in reverse, you use this function.
The reversed() function.
List comprehensions creates…
A list
What is the definition of coding?
The process of assigning a code to something for classification or identification.
How do you declare a variable in Java?
data type variable [ = value][, variable [ = value] …] ;
How are local variables declared?
Local variables are declared in methods, constructors, or blocks.
Object
Objects have states and behaviors. Example: A dog has states - color, name, breed as well as behavior such as wagging their tail, barking, eating. An object is an instance of a class.
Method
A method is basically a behavior. A class can contain many methods. It is in methods where the logics are written, data is manipulated and all the actions are executed.
Instance Variables
Each object has its unique set of instance variables. An object’s state is created by the values assigned to these instance variables.
Case Sensitivity
Java is case sensitive, which means identifier Hello and hello would have different meaning in Java.
Class Names
For all class names the first letter should be in Upper Case. If several words are used to form a name of the class, each inner word’s first letter should be in Upper Case.
Example: class MyFirstJavaClass
Method Names
All method names should start with a Lower Case letter. If several words are used to form the name of the method, then each inner word’s first letter should be in Upper Case.
Example: public void myMethodName()
Program File Name
Name of the program file should exactly match the class name.
When saving the file, you should save it using the class name (Remember Java is case sensitive) and append ‘.java’ to the end of the name (if the file name and the class name do not match, your program will not compile).
But please make a note that in case you do not have a public class present in the file then file name can be different than class name. It is also not mandatory to have a public class in the file.
Example: Assume ‘MyFirstJavaProgram’ is the class name. Then the file should be saved as ‘MyFirstJavaProgram.java’
public static void main(String args[])
Java program processing starts from the main() method which is a mandatory part of every Java program.
Access Modifiers
default, public , protected, private
Non-access Modifiers
final, abstract, strictfp
Types of variables:
Local Variables Class Variables (Static Variables) Instance Variables (Non-static Variables)