Langage C (WIP)

Description

WIP (work in progress)
roussel.m
Flashcards by roussel.m, updated more than 1 year ago More Less
Miki Rana
Created by Miki Rana almost 9 years ago
roussel.m
Copied by roussel.m almost 9 years ago
2
0

Resource summary

Question Answer
stdio.h Bibliothèque: •entrées / sorties •types •définition de macro ♦ Toujours l'intégrer au programme ♦
stdlib.h Bibliothèque : •conversion numériques • allocation de mémoire
string.h Bibliothèque : • fonction sur les chaines de caractères
math.h Bibliothèque : • fonctions mathématiques
Variables ...
char Type: Caractères 1 octet *Valeurs*
int Type: Entier *Taille* *Valeurs*
float Type: Nombre (max 6 décimales) *Taille* *Valeurs*
double Type: Nombre (max 10 décimales) *Taille* *Valeurs*
Déclaration de Variables Allocation d'espace mémoire auquel on associe un nom > type nom; ex: int car_number;
Initialisation de Variables >nom = valeur ; OU >type nom = valeur; (Déclaration + Initialisation)
%d Specifier for integers -32768 to +32767
%f Specifier for floating-point
%c Specifier for a character
%s Specifier for a string of characters
scanf() Requires 2 arguments in the brackets specifying type of data inputted and where to store it to
long int Usually default of int and has range of values from -2,147,483,647 to +2,147,483,648
short int Saves memory space and has range of values from -32,768 to +32,767
Static Variable Defined outside function, can be used inside using "extern int [variable name];"
Casting Process of forcing a variable into a variable of a different data type variable2 = (modifier data-type) variable1; [ float2int = (int)num; ]
Translating Stage of Compilation Compiler translates high-level language in .i file to low-level Assembly language instructions. Generated file is .s file
Assembly Stage of Compilation Assembler converts assembly language to machine code. Generated object file contains conversion in binary and is .o file
Linking Stage of Compilation Linker combines one or more binary object .o files into single executable file. Generated file is in binary and has .exe file
Show full summary Hide full summary

Similar

CHEMISTRY and biology
greenchloe1998
AWS Notes
Stephen Gibbons
Emily Bradford
lori.twichell
Jeu Mystère
Fen Pin
VIM SHORTCUT
Fen Pin
Enter text here
Keith Howe
The CPU
Phie .
Wortschatz Mittelmeerraum
Sarah HERED
Nombre Mystère
Fen Pin
Competitor Analysis, Segmentation
Georgia Tan