Answer:
def sublist(aList):
new_list = []
for s in aList:
if len(s) < 4:
new_list.append(s)
return new_list
Explanation:
Create a function called sublist that takes one parameter, aList
Inside the function, create a new_list that will hold the strings which are less than 4 characters. Create a for loop that iterates through the aList. If a string in aList is less than 4 characters, add it to the new_list. When the loop is done, return the new_list
C) reflected by an object
Answer:
import java.util.*;
import java.util.Scanner;
import java.io.*;
public class Main
{
public static void main(String[] args) {
System.out.println("Enter the percentage:");
Scanner sc1= new Scanner(System.in);
int percent=sc1.nextInt();
switch((int)percent/10)
{
case 10:
case 9:
System.out.println("Grade: A");
break;
case 8:
System.out.println("Grade: B");
break;
case 7:
System.out.println("Grade: C");
break;
case 6:
System.out.println("Grade: D");
break;
case 5:
case 4:
case 3:
case 2:
case 1:
System.out.println("Grade: F");
break;
}
}
}
Explanation:
The program is as mentioned above. The grades are alloted as per the marks.
Answer:
A. 3mn
Explanation:
48 divides by 2 48 = 24 x 2
then =2 x 2 x 12
then = 2 x 2 x 2 x 2 x 3
greatest factorization is 3 therefore,
3mn is the answer