Coding exam 1 Flashcards

1
Q

Comment bien nommer une variable?

A

Pas de majuscule en premier, pas de chiffre et le seul symbole accepte est _

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

Que sert #include <iostream>?</iostream>

A

Pour le cout

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

Que sert #include <iomanip>?</iomanip>

A

Pour les manipulateurs tels que setw(), setprecision(), etc

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

Que sert #include <conio.h>?</conio.h>

A

Pour le getch

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

Que sert #include <string>?</string>

A

Pour la fonction string

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

Getch?

A

Lit un charactere du clavier, mais qui ne le montre pas a l’ecran et n’attend pas que l’utilisateur pese une touche

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

getche?

A

Lit un caractere du clavier, le montre et n’attend pas que l’utilisateur pese sur une touche

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

Ce qui permet d’ecrire?

A

cout

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

Ce qui permet de lire?

A

cin, getline, getch ou getche

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

Combien de lettre y a-t-il en C++?

A

52 car majuscules et minuscules sont differents

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

Comment ecrire un caractere?

A

’ ‘

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

Comment ecrire plusieurs caracterres?

A

” “

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

Comment transformer un caractere en majuscule?

A

Variable = toupper(variable);

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

Comment transormer un caractere en misuscule?

A

Variable = tolower(variable)

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

What do you need for && to be true?

A

Both answers need to be true

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

What do you need for | | to be true?

A

Only one answer needs to be true

17
Q

What do you need for ! to be false(true)?

A

! simply reverses the results, so if I want false, then the original answer has to be true and vice versa

18
Q

What does 0 and 1 mean?

A

0 means false and 1 means true

19
Q

Can you use int with float, yes or not and why?

A

No, because int is for entire numbers and float is for real numbers (with decimals)