import sys
class employee:
def __init__(self,id1,name,salary):
self.id1 = id1
self.name = name
self.salary = salary
e = employee(10,"abc",12000.02)
x = 1
f = 1.1
d = 1111.11
c = 'C'
print "Sizo of integer : " + str(sys.getsizeof(x)) + "bytes \n"
print "Sizo of float : " + str(sys.getsizeof(f)) + "bytes \n"
print "Sizo of double : " + str(sys.getsizeof(d)) + "bytes \n"
print "Sizo of char : " + str(sys.getsizeof(c)) + "bytes \n"
print "Sizo of employee structure : " + str(sys.getsizeof(e)) + "bytes \n"
import sys
array = []
print "\nSize of array: " + str(sys.getsizeof(array)) + "bytes\n"
print "Number of elements in array "
print str(sys.getsizeof(array) / sys.getsizeof(int)) + "\n"
# there is no malloc function
# there is no malloc function
# there is no malloc function
# there is no malloc function
#if name is None:
# print "\nOut of memory!\n"
#else:
# print "\nMemory allocated.\n"
# there is no malloc function
#if name is not None:
# name = raw_input("Enter your name: ")
# print "\nHi " + name + "\n"
# there is no malloc function
#if name is not None:
# name = raw_input("Enter your name: ")
# print "\nHi " + name + "\n"
# del name
# there is no malloc function
#if numbers is None:
# return
#numbers[0] = 100
#numbers[1] = 200
#numbers[2] = 300
#numbers[3] = 400
#numbers[4] = 500
#print "\nIndividual memory segments initialized to:\n"
#for x in range(5):
# print "numbers[" +x+"] = \n" + numbers[x]
# there is no calloc function
#if numbers is None:
# return
# there is no malloc function
#if numbers is None:
# print "\nOut of memory!\n"
# return
#else:
# number = newNumber
# for x in range(10):
# numbers[x] = x * 10
# print "\nExpanded memory:\n"
# for x in range(10):
# print "numbers[" +x+"] = \n" + numbers[x]
# del number
import random
# there is no calloc function
#time
#print "\nMath Quiz\n\n"
#response = raw_input("Enter # of problems: ")
#if op1 is None || op2 is None || answer is None ||result is None:
# print "\nOut of Memory!\n"
# return
#for x in range(response):
# op1[x] = random.randint(1,200) % 100
# op2[x] = random.randint(1,200) % 100
# print "\n" + op1[x] + "+" + op2[x]"
# answer[x] = raw_input("")
# if answer[x] == op1[x] + op2[x]:
# result[x] = 'c'
# else:
# result[x] = 'i'
#print "\nQuiz Results\n"
#print "\nQuestion\tYour Answer\tCorrect\n"
#for x in range(response):
# if result[x] == 'c':
# print op1[x] + "+" + op2[x] + "\t\t" + answer[x] + "\t\tYes\n"
# else:
# print op1[x] + "+" + op2[x] + "\t\t" + answer[x] + "\t\tNo\n"
#del op1
#del op2
#del answer
#del result