python and java Flashcards

bbl drizzzy bbl drizzy woahohoo bbl drizzy bbl drizzzzay

1
Q

what does print(“content”) do and when do u use it

A

it make anything u make the content pop into the screen and u use it when u want text

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

how do u make a variable in python and when do u use it

A

u make a variable by doing x=content and u use it when u wana be lazy and not type the code and just type variable

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

if u put if 5<2: and type print(“5 is greater than 2”) will it show

A

no it will not show because its not true

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

how do u make a comment

A

u put # with anything and its a comment

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

what the script tag used for

A

In HTML, JavaScript code is inserted between

 and 
tags.
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

where do u put functions and what it do

A

a JavaScript function is placed in the <body> section of an HTML page.

The function is invoked (called) when a button is clicked:

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

what does document.write()

A

Using document.write() after an HTML document is loaded, will delete all existing HTML:

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
8
Q

why do we use window in javascript

A

You can skip the window keyword.

In JavaScript, the window object is the global scope object. This means that variables, properties, and methods by default belong to the window object. This also means that specifying the window keyword is optional:

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
9
Q

how to make comments

A

do // dumbass hey thats not nice
i hope u choke on sand

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
10
Q

do all number need to be with decimals

A

no you goffy ah hold the ice guava ice goffy ah looking monkey it can be written in anyway

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
11
Q

are 2. Strings are text, written within double or single quotes:

A

yes lay low on the wiskey

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
12
Q

how to make variable in java

A

var x =content; dumb ass

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
13
Q

whats a freaking operater

A

a operater is something thats makes all the math stuff happen in java * is multiplscation / is divition and ** is power

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
14
Q

whats arithmetic

A

same as a operater

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
15
Q

whats a function

A

a sequence of commands that can be reused together later in a program.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
16
Q

what can u use const for

A

A new Array
A new Object
A new Function
A new RegExp

17
Q

show me a example how to use it for array

A

const cars = [“Saab”, “Volvo”, “BMW”];

18
Q

show me a example of using a const for a object

A

const car = {type:”Fiat”, model:”500”, color:”white”};
(u can still change the object )

19
Q

whats a object

A

its just a variable with more values

20
Q

how u use a object

A

u use it for using a variable for values

21
Q

show me some code for object

A

// Create an Object:
const person = {firstName:”John”, lastName:”Doe”, age:50, eyeColor:”blue”};

// Display Data from the Object:
document.getElementById(“demo”).innerHTML =
person.firstName + “ is “ + person.age + “ years old.”;
</script>

22
Q

if u want something to appear how do u use object for that

A

so use const then say the object name and when u want to use it type indexHTML=”tthevariablename.the name of object

23
Q
A