WorksheetsFlutter Quiz
Total questions: 36
Worksheet time: 27mins
var l = [2,4,6,8];
print(l.index of (2));
what is the output of this code?
0
6
null
8
var l = [2,4,6,8];
print(l.elementAt(2));
what is the output of this code?
6
0
8
null
var l = [2,4,6,8];
print(l.reversed);
what is the output of this code?
(8,6,4,2)
8,4,6,2
[8,4,6,2]
{8,4,6,2}
var l = [2,4,6,8]; l.replaceRange(3, 4, 18);
print(l);
what is the output of this code?
Error
2,4,6,18
2,4,6,8
No OutPut
var l = [2,4,6,8]; l.replaceRange(2, 3, [18]);
print(l[1]);
what is the output of this code?
6
0
4
18
var x =new List(2,2); x=[[2,4],[2,8]] ;
print (x);
what is the output of this code?
[[2,4],[2,8]]
2,4,2,8
[[2,8],[2,4]]
Error
all is wrong
var x =[[2,4,6],[2,8,9]]; print(x[3]);
what is the output of this code?
Error
[2,8,9
6
9
2
var x =[[2,4,6],[2,8,9]]; print(x[0]);
what is the output of this code?
2
Error
[2,2]
[2,4,6]
var x =[[2,4,6],[2,8,9]]; print(x[0][2]);
what is the output of this code?
6
Error
2,9
[2,9]
var y=[2,4,8]; var t={6,4,9};
print(t.intersection(y));
what is the output of this code?
Error
[4]
{4}
4
Null
var n ={2,4,6}; var o={4,8,6};
print(n.difference(o));
what is the output of this code?
{2}
Error
8
NAN
var n ={2,4,6}; var o={4,8,6};
print(o.difference(n));
what is the output of this code?
{8}
2
Error
Null
var p ={[2,4],6,8};print(p);
what is the output of this code?
Error
2,4,6,8
{[2,4],6,8}
{2,4,6,8}
var p ={[2,4],6,8};print(p.elementAt(0));
what is the output of this code?
[2,4]
Error
Null
NAN
var p ={[2,4]}; for (var x in p ){print(x[0]);}
what is the output of this code?
2
Error
Null
NAN
var p ={[2,4],6}; for (var x in p ){print(x[0]);}
what is the output of this code?
Error
[2,4]
Null
2
var m={12,6,8,6,7};print(m.removeAll({6}));
what is the output of this code?
{12,8,7}
Null
Error
NAN
var t ={12,7,9}; t.addAll({15,5,6}); print(t);
what is the output of this code?
{12,7,9,15,5,6}
Error
Null
var m ={15,12,9}; m.addAll({9,7,15}); print(m);
what is the output of this code?
{15,12,9,7}
{15,12,9,9,7,15}
Error
var stud={"ID":1521};
print(user.contiansKey("id"));
what is the output of this code?
True
False
1521
Error
var employee={"Name":"Ali"};
print(employee.clear());
what is the output of this code?
Error
True
{}
False
var user={33 : "ahmed"}; user["Name"]="33";
print(user.contiansKey("33"));
True
Error
ahmed
False
var car ={id="2525"};
print(car.contiansKey(id));
True
2525
False
Error
const x; x=10;
print(x);
what is the output of this code?
Error
10
Null
NAN
var p ={1,4,8,7};p.remove({1,8});
print(p);
What is the output of this code?
{1, 4, 8, 7}
{4,7}
{0,4,0,7}
Error
main(){ h1(); }
h1() =>"hi"+"text";
What is the output of this code?
hi text
hi
Null
Error
No Output
main(){ sum(2,5,2); }
int sum ({x,y,z}) {print(x+y+z);}
What is the output of this code?
9
Null
x+y+z
Error
main() { sum(x:2,z:"5",y:8); }
sum ({x,y,String z}) {print(x+y);}
What is the output of this code?
Error
Null
10
can we pass to a function an argument string list only?
True
False
main(){ print(div(12,3) );}
var div = (x,y)=>x/y;
What is the output of this code?
Error
Null
4
None From Above
can we pass a function as an argument in another function?
True
False
is there an error in making a function inside class?
yes there is an error
no there is no error
can we make a function inside a class its name same as the class name?
True
False
can we put a lamda function in variable?
True
False
line 1 main()
line 2 { human h1=new human();
line 3 human h2=human();}
line 4 class human{var name;}
Is there an error?
Yes at line 3
Yes at line 4
Yes at line 2
No Error
var l = [2,4,6,8]; l.replaceRange(3, 4, [18]);
print(l);
What is the Output of this code?
[2, 4, 6, 18]
Error
[2,4,6,8,18]
