Which
one is the true regarding awk command?
a. BEGIN and END blocks are not mandatory in all awk commands
b. Both
BEGIN and END blocks are mandatory in all awk commands
c. A
END block is always mandatory whereas BEGIN block is not
d. A BEGIN block is always mandatory whereas END block is not
Which option/opinions correctly
represent the code of creating and initializing a string variable?
a.
var str1=’Hello’;
b.
var
str1=’’’Hello’’’;
c.
var
str1=Hello;
d.
var str1=”Hello”;
Which
of the following CSS syntax will be hiding the element?
a.
h1.hidden{
display:
hidden;}
b.
h1.hidden{ visibility: hidden;}
c.
h1.hidden{
visibility:
none;}
d. h1. hidden { display: none;}
Which vi command should one use to delete the first 10 lines
of a file in Normal mode?
a.
gg10dd
b.
10ggdd
c.
10dw
d.
10ddl
/ Command is used to search text in the ______ in VI editor
a.
forward direction
b.
backward direction
c.
any direction
d. reversed
direction
Which command can I used to change the owner and also the
group of a file?
a.
chgrp
b.
chown
c.
chmod
d. umask
UNIX provides multi-tasking by
a. Parallel processing
b. Time sharing
c. multiple processors
d. multi users
Which of the following command will be used for searching
“director” in emp.lst?
a.
grep
“director” emp.lst
b.
grep
-director emp.lst
c.
grep -v “director” emp.lst
d.
grep
“director”
What is the
meaning of the below fetch statement?
FETCH c1 INTO
ename, empno, sal;
EXIT WHEN
(c1%ROWCOUNT > 5) OR (c1%NOTFOUND);
a. fetch statement ends only when no records returned by
the cursor
b. fetch statement ends either when the number of rows
returned by the cursor is greater than 5 or no records returned by the cursor
c. Syntax error
d. None of the options
What would be the
output of the following program?
class CharRange {
public static void
main(String[] args) {
char ch=127; ch++;
System.out.println(ch+"
= " +(int)ch); } }
a. ? = 128
b. GarbageCharacter = -128
c. Compiler Error
d. None of the options
class string_class
{public static void main(String args[]) {
String obj = "I
LIKE JAVA";
System.out.println(obj.length());
} } What will be the output?
a. 9
b. 10
c. 11
d. 12
Which of the options
are true regarding primary key and foreign key?
a. Primary key cannot be null on the other hand foreign key
can be null.
b. Primary key is always unique while foreign key can be
duplicated
c. There can be only
one primary key in the table and only one foreign key in the table.
d. There can be only
one primary key in the table on the other hand we can have more than one
foreign key in the table.
What is the output of
below code?
TCS = (1, 4, 9)
print(type(TCS))
a. <type ‘tuple’>
b. <type ‘list’>
c. Array
d. <type
‘dict’>
Which of the
following commands can be used to delete a column age from a table with name
test1?
a. alter table test1 drop column age;
b. alter table test1 drop age;
c. drop table test1;
d. delete from test1 age;
Which of the
following are valid constraints in MySQL?
a. UNIQUE, NOT NULL
and DEFAULT
b. UNIQUE, NOT NULL
and DISTINCT
c. DISTINCT and DEFAULT
d. DEFAULT, NOT NULL and DISTINCT
0 Comments