View difference between Paste ID: AQBDbS0E and fHpQ0hyZ
SHOW: | | - or go back to the newest paste.
1
# haiku function function
2
poem = ["Have we not known, nor heard, nor read",
3
        "How God does hate deceit and wrong?",
4
        "How Ananias was struck dead,",
5
        "Caught with a lie upon his tongue?"]
6
def display_haiku():
7
    for line in poem:
8
        print(line)
9
display_haiku()
10
11
12
#Triangle area function
13
def triangle_area():
14
    height = float(input('Enter the height of the triangle: '))
15
    base = float(input('Enter the base of the triangle: '))
16-
    
16+
17-
triangle_area()
17+
18
    triangle_area()
19
20
21
# heads and tails function
22
import random
23
def heads_or_tails():
24
    r =random.randint(0,1)
25
    if r == 0:
26
        print('heads')
27
    if r == 1:
28
        print('tails')
29
        
30
heads_or_tails()