print ("-----------------------------------")
print ("    PROGRAM HITUNG RATA-RATA")
print ("-----------------------------------")

x= True
sum = 0
jumlah = 0
while ( x == True):
    try :
        bilbulat = int(input("Masukkan Bilangan Bulat : "))
        sum += bilbulat
        jumlah +=1

        opsi = input("Lagi ? (y/n) : ")
        if(opsi == "y"):
            x = True
        elif(opsi == "n"):
            x = False
        else :
            print ("Input Tidak Valid")
            break
    except ValueError :
        print("Bukan Bilangan Bulat")
        continue
rata2 = sum / jumlah
print("Rata-ratanya adalah : ", rata2)
        

e99dedbd6be1527565108195694d47e3303f7d39
<mask token>

print('-----------------------------------')
print('    PROGRAM HITUNG RATA-RATA')
print('-----------------------------------')
<mask token>
while x == True:
    try:
        bilbulat = int(input('Masukkan Bilangan Bulat : '))
        sum += bilbulat
        jumlah += 1
        opsi = input('Lagi ? (y/n) : ')
        if opsi == 'y':
            x = True
        elif opsi == 'n':
            x = False
        else:
            print('Input Tidak Valid')
            break
    except ValueError:
        print('Bukan Bilangan Bulat')
        continue
<mask token>
print('Rata-ratanya adalah : ', rata2)

print('-----------------------------------')
print('    PROGRAM HITUNG RATA-RATA')
print('-----------------------------------')
x = True
sum = 0
jumlah = 0
while x == True:
    try:
        bilbulat = int(input('Masukkan Bilangan Bulat : '))
        sum += bilbulat
        jumlah += 1
        opsi = input('Lagi ? (y/n) : ')
        if opsi == 'y':
            x = True
        elif opsi == 'n':
            x = False
        else:
            print('Input Tidak Valid')
            break
    except ValueError:
        print('Bukan Bilangan Bulat')
        continue
rata2 = sum / jumlah
print('Rata-ratanya adalah : ', rata2)

print ("-----------------------------------")
print ("    PROGRAM HITUNG RATA-RATA")
print ("-----------------------------------")

x= True
sum = 0
jumlah = 0
while ( x == True):
    try :
        bilbulat = int(input("Masukkan Bilangan Bulat : "))
        sum += bilbulat
        jumlah +=1

        opsi = input("Lagi ? (y/n) : ")
        if(opsi == "y"):
            x = True
        elif(opsi == "n"):
            x = False
        else :
            print ("Input Tidak Valid")
            break
    except ValueError :
        print("Bukan Bilangan Bulat")
        continue
rata2 = sum / jumlah
print("Rata-ratanya adalah : ", rata2)
        
