-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathVariables.c
34 lines (31 loc) · 1016 Bytes
/
Variables.c
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
#include <stdio.h>
/// @brief
/// @return
int main(){
// Print Text Command!!
/*
\a - Alert [Beep, Bell]
\b - Backspace
\e - Escape character
\f - Formfeed Page Break
\n - Newline [Line feed]
\r - Carriage Return
\t - Horizontal Tab
\v - Vertical Tab
\\ - Backslash
\' - Apostrophe, Single Quotation Mark
\" - Double Quotation Mark
*/
int x; //DECLARATION
x = 123; //INITIALIZATION
int y = 321; //DECLARATION + INITIALIZATION
int age = 18; //INTEGER
float gpa = 1.40; //FLOATING POINT NUMBER
char grade = 'B'; //SINGLE CHARACTER
char name[] = "Luna"; //ARRAY OF CHARACTERS
printf("Hello there %s.\n",name);
printf("You are %d years old!\n",age);
printf("So, your average grade is %c.\n",grade);
printf("Your GPA is %f, Keep it up!\n",gpa);
return 0;
}