Skip to content

Commit 9dca5a6

Browse files
committed
Added till 24
1 parent 7176d16 commit 9dca5a6

File tree

17 files changed

+81
-7
lines changed

17 files changed

+81
-7
lines changed

.learn/resets/016-century/app.py

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
# Complete the function to return the respective number of the century
2+
def century(year):
3+
return None
4+
5+
6+
# Invoke the function with any given year
7+
print(century())

.learn/resets/017-total_cost/app.py

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
# Complete the function to return the total cost in dollars and cents of (n) cupcakes
2+
def total_cost(d, c, n):
3+
return None
4+
5+
6+
# Invoke the function with three integers: total_cost(dollars, cents, number_of_cupcakes)
7+
print(total_cost(15,22,4))

.learn/resets/018-day_of_week/app.py

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
# Complete the function to return the number of day of the week for k'th day of year
2+
def day_of_week(k):
3+
return None
4+
5+
6+
# Invoke function day_of_week with an integer between 1 and 365
7+
print(day_of_week())
Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
# Complete the function to return how many hours and minutes are displayed on the 24h digital clock
2+
def digital_clock(n):
3+
return None
4+
5+
# Invoke the function with any integer (minutes after midnight)
6+
print(digital_clock())

.learn/resets/020-factorial/app.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
# Your code here

.learn/resets/021-square_root/app.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
# Your code here

.learn/resets/022-Integral/app.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
# Your code here
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
# Your code here
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
# Your code here

exercises/016-century/app.py

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,12 @@
11
# Complete the function to return the respective number of the century
2+
import math
3+
24
def century(year):
3-
return None
5+
if year % 100 == 0:
6+
return math.floor(year/100)
7+
else:
8+
return math.floor((year/100))+1
49

510

611
# Invoke the function with any given year
7-
print(century())
12+
print(century(2024))

0 commit comments

Comments
 (0)