-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathreverse.py
More file actions
36 lines (30 loc) · 811 Bytes
/
Copy pathreverse.py
File metadata and controls
36 lines (30 loc) · 811 Bytes
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
# def reve(s):
# return s[::-1]
# print(reve("krishna"))
# def reve(s):
# return reve(s[::-1])+s[0]
# print(reve("krishna"))
# def work1(f1,s1):
# return f1*s1
# def work2(f2,s2):
# return f2*s2
# def work():
# f1=int(input("enter F1: "))
# s1=int(input("enter s1: "))
# f2=int(input("enter f2: "))
# s2=int(input("enter s2: "))
# if((f1 or s1 or f2 or s2)<0):
# return "error"
# else:
# return max(work1(f1,s1),work2(f2,s2)),work1(f1,s1)+work2(f2,s2)
# print(work())
# def flip(state,n):
# if(state=="H" and n%2==0):
# return "H"
# elif(state=="H" and n%2!=0):
# return "T"
# elif(state=="T" and n%2==0):
# return "T"
# else:
# return "H"
# print(flip("H",5))