-
Notifications
You must be signed in to change notification settings - Fork 9
/
Hafta3_Sec2_21022019.py
76 lines (76 loc) · 1.17 KB
/
Hafta3_Sec2_21022019.py
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
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
#https://repl.it/languages/python3 ile oluţturuldu.
print("Merhaba")
a=10
print(a)
a="Merhaba"
print(a)
print(a[0])
print(a[0:3])
print(a[3:5])
print(a[::2])
print(a[::-1])
print(type(a))
b=10
print(type(b))
c=4.5
print(type(c))
d=True
print(type(d))
a="3.5"
a=float(a)
print(type(a))
print(int(a))
print(round(a))
a=5
b=6
x=a
a=b
b=x
print(a,b)
a,b=b,a
print(a,b)
a,b,c,d=1,2,3,4
print(a,b,c,d)
a=[1,2,3,4,5]
print(type(a))
a=["Beykoz","2.3",5,True]
print(a[0])
print(a[0][0])
print(a[1][0])
a={1,2,3,4}
print(a)
a.add(10)
print(a)
a.add("Kavacýk")
print(a)
print(5/3)
print(5//3)
print(5%3)
print(5**3)
print(16**(1/2))
print(16**0.5)
print(8**(1/3))
a=4
print(-a)
a=-a
print(a)
a='Gözde\'nin bugün dersi var'
print(a)
a='Gözde \t nin bugün dersi var'
print(a)
print(len(a))
a="Beykoz"
print(a[len(a)-1])
print(a[-1])
print(12,34,23,sep=".")
print(12,34,23,sep=" ")
print(21,2,2019,sep="/")
print(21,2,2019,sep="\n")
print(*"Python")
print(*"123")
print(123,212,331,sep=",")
a,b,c=10,10.5,345.234
print("{2} {0} {1}".format(a,b,c))
print("{:10.2f}".format(a))
print("{:10.2f}".format(b))
print("{:10.2f}".format(c))