DAY 3: --------- 1.binary,octal,hexadecimal to decimal conversion 2.bin(),oct(),hex() 3.int(),float(),complex(),bool(),str() QUESTIONS(Theory) ----------------------------- 1.How to declare a binary number? 2.How to declare a octal number? 3.How to declare a hexadecimal number? 4.What are the datatypes available in python? 5.Do we need to declare the datatype for a variable in python? 6.How to declare a variable in python? 7.can i print a variable before its declaration? print(a) a=10 QUESTIONS(Practical) ----------------------------- QUESTION 1: ------------------ Description: Convert the below binary number into decimal number:- a.0b11100 b.0B11011001 c.0b101010 QUESTION 2: ------------------ Description: Convert the below octal number into decimal number:- a.0o74 b.0O37246 c.0o321 QUESTION 3: ------------------ Description: Convert the below hexadecimal number into decimal number:- a.0x3c b.0XA2F7 c.0xFACE QUESTION 4: ------------------- Description: Convert the given numbers in to binary number: a.123 b.0o123 c.0x1AF QUESTION 5: ------------------- Description: Convert the given numbers in to octal number: a.123 b.0b111 c.0xFACE d.0x1AF QUESTION 6: ------------------- Description: Convert the given numbers in to hexadecimal number: a.1 b.0 e.0b1111 f.0o123 g.123 QUESTION 7: ------------------- Description: Convert the given value into "int" type:- a.0b0011 b.0o123 c.0xFACE d.12 e.1.5 f.2+10j QUESTION 8: ------------------- Description: Find the output for given possiblities: a.int(True) b.int(True/True) c.int(True/False) d.int('python') QUESTION 9: ------------------- Description: Convert the given value into "float" type:- a.10 b.12.8 c.0b11 d.0o321 e.0xABC QUESTION 10: -------------------- Description: Find the output for given possiblities: a.float(True) b.float(False) c.float('python') d.float(10+2j) e.float(True/True) f.float(True/False) QUESTION 11: -------------------- Description: Convert the given value into "complex" type:- a.10 b.12.0 c.0b11 d.0o32 e.0x1F QUESTION 12: -------------------- Description: Find the output for given possiblities: a.complex(True) b.complex(False) c.complex('python') d.complex(True/True) e.complex(True/False) QUESTION 13: -------------------- Description: Convert the given value into "bool" type:- a.0o123 b.0x1F c.12 d.10.5 e.1+2j QUESTION 14: -------------------- Description: Find the output for given possiblities: a.bool() b.bool("") c.bool(0) d.bool(1) e.bool(True) f.bool(False) g.bool(True/True) h.bool(True/False) QUESTION 15: -------------------- Description: Convert the given value into "str" type:- a.10 b.10.5 c.10+2j d.0b0011 e.0o145 f.0xAB QUESTION 16: -------------------- Description: Find the output for given possiblities: a.str(True) b.str(False) c.str(10,20) d.str("10",20) e.str(20+"10")