Uncategorized

Differential between fruitful function and non-fruitful function

Fruitful Function: Function that returns a value def power(x,y):   for i in range(y):     r=r*x   print(r) a=intinput((“Enter Base”)) b=intinput((“Enter Exponent”)) power(a,b) Non-Fruitful Function: Function that does not return any value. def power(x,y=3):   for i in range(y):     r=r*x   return r a=intinput((“Enter Base”)) b=intinput((“Enter Exponent”)) total = power(a,b) print(total)

Differential between fruitful function and non-fruitful function Read More »

20. Below are seven segment of code, each with part colored. Indicate the data type of each colored part by choosing the correct type of data from the following type.
(a) int (b) float (c) bool (d) str (e) function (f) list of int (g) list of str

20. Below are seven segment of code, each with part colored. Indicate the data type of each colored part by choosing the correct type of data from the following type.
(a) int (b) float (c) bool (d) str (e) function (f) list of int (g) list of str
Read More »

2. What will be the output of the following code?
2. SELECT CONCAT (CONCAT(‘Inform’, ‘atics’), ‘Practices’);
3. SELECT LCASE (’INFORMATICS PRACTICES CLASS 11TH‘);
4. SELECT UCASE (’Computer Studies‘);
5. SELECT CONCAT (LOWER (‘Class’), UPPER (‘xii’));

Ans 2:InformaticsPracticesAns 3:informatics practices class 11thAns 4:COMPUTER STUDIESAns 5:classXII

2. What will be the output of the following code?
2. SELECT CONCAT (CONCAT(‘Inform’, ‘atics’), ‘Practices’);
3. SELECT LCASE (’INFORMATICS PRACTICES CLASS 11TH‘);
4. SELECT UCASE (’Computer Studies‘);
5. SELECT CONCAT (LOWER (‘Class’), UPPER (‘xii’));
Read More »

18.What is missing data? 19. Why is missing data filled in Dataframe with some value? 20. Name the function you can use for filling missing data? 21. Name some function to handle missing data.

Ans:18. NA values such as NULL or NaN or None values which can not participate in any computation are called missing values.19. To calculate accurate result or predictions from given data, missing data should be handled or filled.20. fillna(<n>)21. dropna(), fillna(), isnull()

18.What is missing data? 19. Why is missing data filled in Dataframe with some value? 20. Name the function you can use for filling missing data? 21. Name some function to handle missing data. Read More »

error: Content is protected !!