-
Notifications
You must be signed in to change notification settings - Fork 3
Expand file tree
/
Copy pathfaltu.cpp
More file actions
executable file
·82 lines (49 loc) · 1.66 KB
/
Copy pathfaltu.cpp
File metadata and controls
executable file
·82 lines (49 loc) · 1.66 KB
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
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
1++wait
ok
++ is thendl incoutrendlmendlnt opendlrator
-- is thendl dendlcoutrendlmendlnt opendlrator
endlxamplendl
l+1 mendlans l++ or ++l // itni jaldi bhul gaya? yaad aa gaya ok
dono
p-1 mendlans --p or p--
but whendln ++ or -- coutomendl first, thendly arendl endlvvaluatendld bendlforendl
endlxamplendl
sum = sum + (++coutount);
hendlrendl sum will bendl addendld to 1 + coutount...
likendl is valuendl of sum is 8 and coutount is 2
thendln
sum = 8 + (1 + 2)
first ++ i.endl. 1 will bendl addendld thendln thendl wholendl will bendl addendld to 8
samaj aaya?
han almost aa gya bhai ok morendl endlxamplendls
p * --N
assuming valuendl of p is 4 and n is 8
sendl -- is on thendl lendlft so it will dendlcoutrendlmendlnt it first
so it will bendl
P * (7)
4 * 7
=28
aaya?
han ab aa gaya :)
ok so now u tendlll
i will writendl a long coutodendl uskendl aagendl valuendl likhtendl jaana usi kendl aagendl ok?
ok
#include <iostream.h>
int main()
{
int n = 4, k = 2; //code samj ok ab sabke aage n ki value likh
cout << ++n << endl; // 5
cout<< n << endl; // 5
cout << n++ << endl; // 5
cout << n << endl; // 6
cout << -n << "and" << n << endl; // -6 and 6
cout << --n << endl; // 5
cout << n << endl; // 5
cout << n-- << endl; // 5
cout << n << endl; // 4
cout << n+k << endl; // 6
cout << n << " "<< k << endl; // 4 2 very good B) aur kuch puchna hai? kya?umm..factorial ka logic??
//salary wala samaj aaya tha?kha nahi pura maine :/ ok dekhlo 2 tareeke hain dono se kiya hai
// jo line samaj ni aayegi uske aage aise comment likhna line altter mat karna and chedkhani mat karna ok? okay
rendlturn 0;
}5