0% found this document useful (0 votes)
53 views

CC1551 - Web Technologies End Term Examination Jan 2020

This document appears to be an exam for a course on web technologies. It contains 27 multiple choice questions testing various concepts in JavaScript, PHP, HTML, XML, and CSS. The questions cover topics like arrays, functions, operators, DOM, sockets, and more. The exam is asking students to select the correct answer for each question.

Uploaded by

Rey Daniels
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
53 views

CC1551 - Web Technologies End Term Examination Jan 2020

This document appears to be an exam for a course on web technologies. It contains 27 multiple choice questions testing various concepts in JavaScript, PHP, HTML, XML, and CSS. The questions cover topics like arrays, functions, operators, DOM, sockets, and more. The exam is asking students to select the correct answer for each question.

Uploaded by

Rey Daniels
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 20

19/01/2021 CC1551- Web Technologies End Term Examination Jan 2020

CC1551- Web Technologies


End Term Examination Jan 2020
CC1551- Web Technologies
B. Tech CSE/IT/CCE V Semester


Hi Namanpreet, when you submit this form, the owner will be able to see your name and email address.

* Required

Your Name *

Enter your answer

Registration No *

Enter your answer

Department *

https://forms.office.com/Pages/ResponsePage.aspx?id=3S8oJwtM-026kSKM2D_fcShSlO6Hg81HoSyJRML7B8lUMjFMNEM3VU5CQ0JNVTFIME9J… 1/20
19/01/2021 CC1551- Web Technologies End Term Examination Jan 2020

CSE

IT

CCE

Section *

The output of the below code is


var city = new Array("calcutta", "agra", "Ajmer", "aligarh","Kota");
console.log(city.pop());
(1 Point)

Aligarh

calcutta

Kota

Ajmer

agra

https://forms.office.com/Pages/ResponsePage.aspx?id=3S8oJwtM-026kSKM2D_fcShSlO6Hg81HoSyJRML7B8lUMjFMNEM3VU5CQ0JNVTFIME9J… 2/20
19/01/2021 CC1551- Web Technologies End Term Examination Jan 2020

What will be the output of the following JavaScript code?


x = 1;
console.log('x = ' + x);
var x;
(1 Point)

undefined

null

error: x is undefined

What will be the output of the following PHP code?


1. <?php
2. function calc($price, $tax="")
3. {
4. $total = $price + ($price * $tax);
5. echo "$total";
6. }
7. calc(42);
8. ?>
(1 Point)

82

error

42

https://forms.office.com/Pages/ResponsePage.aspx?id=3S8oJwtM-026kSKM2D_fcShSlO6Hg81HoSyJRML7B8lUMjFMNEM3VU5CQ0JNVTFIME9J… 3/20
19/01/2021 CC1551- Web Technologies End Term Examination Jan 2020

The function used to change the root directory in PhP is


(1 Point)

cd_root()

chnage_root()

cd_r()

chroot()

Which of the following statements are true?


(1 Point)

HTTP can be used to test the validity of a hypertext link

UDP is connection oriented protocol

HTTP allows information to be stored in a URL

HTTP runs over TCP

10

The correct way the Java Script store dates in objects of Date type is?
(1 Point)

The number of days since 1st, 1900

The number of picoseconds since January 1st, 1970

The number of milliseconds since January 1st, 1970

https://forms.office.com/Pages/ResponsePage.aspx?id=3S8oJwtM-026kSKM2D_fcShSlO6Hg81HoSyJRML7B8lUMjFMNEM3VU5CQ0JNVTFIME9J… 4/20
19/01/2021 CC1551- Web Technologies End Term Examination Jan 2020

The number of seconds since January 1st, 1970

11

What will be the output of the following PHP code?


1. <?php
2. $op2 = "Rama";
3. function foo($op1)
4. {
5. echo $op1;
6. echo $op2;
7. }
8. foo("hello");
9. ?>
(1 Point)

b) Error

c) hello

d) helloRamaRama

helloRama

12

$_SESSION[] in PHP is used for?


(1 Point)

Used to initialize a session.

Used to register a global variable

Used to store variables of the current session

none of the above

https://forms.office.com/Pages/ResponsePage.aspx?id=3S8oJwtM-026kSKM2D_fcShSlO6Hg81HoSyJRML7B8lUMjFMNEM3VU5CQ0JNVTFIME9J… 5/20
19/01/2021 CC1551- Web Technologies End Term Examination Jan 2020

13

in XML, the words Document Node, Nodelist, Element Node, Named Node Map
etc. are
(1 Point)

Objects

Attributes

Elements

Interfaces

14

Which of the following CSS3 property can be used to allow line breaks within
words?
(1 Point)

word-wrap

line-break

word-break

line-wrap

15

____________ function in PHP returns a list of response headers sent (or ready to
send)
(1 Point)

header()

headers_list()

https://forms.office.com/Pages/ResponsePage.aspx?id=3S8oJwtM-026kSKM2D_fcShSlO6Hg81HoSyJRML7B8lUMjFMNEM3VU5CQ0JNVTFIME9J… 6/20
19/01/2021 CC1551- Web Technologies End Term Examination Jan 2020

header_sent()

header_send()

16

(document.getElementById("demo").innerHTML = "Hello!"; ) Function is an


example of?
(1 Point)

None

JavaScript

HTML5

PHP

17

Check whether the following given statements for the Strictly equal operator are
true or false:
a) If the data type of two values are equal, they are Equal.
b) If both values are undefined and both are null, they are Equal.
(1 Point)

False, False

True, False

False, True

Ture, True

https://forms.office.com/Pages/ResponsePage.aspx?id=3S8oJwtM-026kSKM2D_fcShSlO6Hg81HoSyJRML7B8lUMjFMNEM3VU5CQ0JNVTFIME9J… 7/20
19/01/2021 CC1551- Web Technologies End Term Examination Jan 2020

18

The correct function to find the index of a particular string?


(1 Point)

positionof()

position()

indexOf()

index()

19

In HTML web sockets are not available whereas in HTML5


(1 Point)

No networking capability available

Still it is not available

All of above

Full duplex communication channel is present

20

In HTML, hexadecimal values each color defines the intensity between?


(1 Point)

0 - 16

0 - FF

0 - 250

https://forms.office.com/Pages/ResponsePage.aspx?id=3S8oJwtM-026kSKM2D_fcShSlO6Hg81HoSyJRML7B8lUMjFMNEM3VU5CQ0JNVTFIME9J… 8/20
19/01/2021 CC1551- Web Technologies End Term Examination Jan 2020

0 - 256

21

In XML, How DOM differs from SAX?


(1 Point)

SAX is event driven and requires less space

DOM and SAX are packages

None of these

DOM is not event driven and builds up the whole memory

22

What if we define a "for" loop and it removes one of the properties that has not
yet been enumerated?
(1 Point)

The removed property will be stored in a cache

That specific property will not be enumerated

That property will be enumerated

The loop will not run at all

23

Which of the following PHP functions can be used to get the current memory
usage?
(1 Point)

get_usage()

https://forms.office.com/Pages/ResponsePage.aspx?id=3S8oJwtM-026kSKM2D_fcShSlO6Hg81HoSyJRML7B8lUMjFMNEM3VU5CQ0JNVTFIME9J… 9/20
19/01/2021 CC1551- Web Technologies End Term Examination Jan 2020

get_peak_usage()

memory_get_peak_usage()

memory_get_usage()

24

What will be the output of the following JavaScript code?


var x = 0
do{ console.log(x) }while(x > 0)
(1 Point)

Null

No output

25

Which function displays the information about PHP?


(1 Point)

phpinfo()

sysinfo()

php_info()

info()

https://forms.office.com/Pages/ResponsePage.aspx?id=3S8oJwtM-026kSKM2D_fcShSlO6Hg81HoSyJRML7B8lUMjFMNEM3VU5CQ0JNVTFIME9… 10/20
19/01/2021 CC1551- Web Technologies End Term Examination Jan 2020

26

What will be the output of the following PHP code


(1 Point)

Display a folder content

None of above

Display all the folder names

Display content of all the drives

27

What will the output of the following PHP code?


(1 Point)

https://forms.office.com/Pages/ResponsePage.aspx?id=3S8oJwtM-026kSKM2D_fcShSlO6Hg81HoSyJRML7B8lUMjFMNEM3VU5CQ0JNVTFIME9… 11/20
19/01/2021 CC1551- Web Technologies End Term Examination Jan 2020

X=42

null

42

56

28

The function that returns the primitive value of the Boolean object is?
(1 Point)

valueOf()

toSource()

None of These

toString()

https://forms.office.com/Pages/ResponsePage.aspx?id=3S8oJwtM-026kSKM2D_fcShSlO6Hg81HoSyJRML7B8lUMjFMNEM3VU5CQ0JNVTFIME9… 12/20
19/01/2021 CC1551- Web Technologies End Term Examination Jan 2020

29

What will be the output of the following PHP code?


1. <?php
2. $foo = 'Bob';
3. $bar = &$foo;
4. $bar = "My name is $bar";
5. echo $bar;
6. echo $foo;
7. ?>
(1 Point)

My name is Bob Bob

Error

My name is BobMy name is Bob

My name is BobBob

30

An HTML form is designed to buy office furniture. All the products required are
being checked. After selecting the products the payment details are entered
and the submit button is pressed. From the following options which one would
you prefer to send the data to the server. Assume that all the security is
handled.
(1 Point)

Only POST

Either GET nor POST

Only GET

Neither GET nor POST

https://forms.office.com/Pages/ResponsePage.aspx?id=3S8oJwtM-026kSKM2D_fcShSlO6Hg81HoSyJRML7B8lUMjFMNEM3VU5CQ0JNVTFIME9… 13/20
19/01/2021 CC1551- Web Technologies End Term Examination Jan 2020

31

During error handling in PHP, include() generates


(1 Point)

No warning

A fatel error and script will stop

none of above

A warning but, script will continue to execute

32

What will be the value of $a and $b after the function call in the following PHP
code?
1. <?php
2. function doSomething( &$arg ) {
3. $return = $arg;
4. $arg += 1;
5. return $return;
6. }
7. $a = 3;
8. $b = doSomething( $a );
9. ?>
(1 Point)

a is 3 and b is 4

a is 4 and b is 3

Both are 3

Both are 4

https://forms.office.com/Pages/ResponsePage.aspx?id=3S8oJwtM-026kSKM2D_fcShSlO6Hg81HoSyJRML7B8lUMjFMNEM3VU5CQ0JNVTFIME9… 14/20
19/01/2021 CC1551- Web Technologies End Term Examination Jan 2020

33

Which of the following variables takes precedence over the others if the names
are the same?
(1 Point)

The local element

Global variable

The two of the above

None of the above

34

What will happen, if the following JavaScript code is executed?


1. var count =0;
2. while (count <10)
3. {
4. console.log(count);
5. count++;
6. }
(1 Point)

An error is displayed

An exception is thrown

The values of count variable are logged or stored in a particular location or storage

The value of count from 0 to 9 is displayed in the console

https://forms.office.com/Pages/ResponsePage.aspx?id=3S8oJwtM-026kSKM2D_fcShSlO6Hg81HoSyJRML7B8lUMjFMNEM3VU5CQ0JNVTFIME9… 15/20
19/01/2021 CC1551- Web Technologies End Term Examination Jan 2020

35

From following options indicate a correct association of the PROMPT, HEAD


and RCPT commands with protocols where they are used?
(1 Point)

HTTP, FTP, SMTP

SMTP, HTTP, FTP

HTTP, SMTP, FTP

FTP, HTTP, SMTP

36

Which of the following are correct ways of creating an array?


i) state[0] = "karnataka";
ii) $state[] = array("karnataka");
iii) $state[0] = "karnataka";
iv) $state = array("karnataka");
(1 Point)

iii

iv

ii

https://forms.office.com/Pages/ResponsePage.aspx?id=3S8oJwtM-026kSKM2D_fcShSlO6Hg81HoSyJRML7B8lUMjFMNEM3VU5CQ0JNVTFIME9… 16/20
19/01/2021 CC1551- Web Technologies End Term Examination Jan 2020

37

What will be the output of the following PHP code?


1. <?php
2. $user = array("Lokesh", "Rakesh", "Neeraj", "Amit");
3. for ($x=0; $x < count($user); $x++) {
4. if ($user[$x] == "Neeraj") continue;
5. printf ($user[$x]);
6. }
7. ?>
(1 Point)

Option 2

NeerajAmit

LokeshRakeshAmit

NeerajLokesh

LokeshRakesh

38

How to apply strict mode in JavaScript?


(1 Point)

"apply strict"

"strict mode"

"strict"

"use strict"

https://forms.office.com/Pages/ResponsePage.aspx?id=3S8oJwtM-026kSKM2D_fcShSlO6Hg81HoSyJRML7B8lUMjFMNEM3VU5CQ0JNVTFIME9… 17/20
19/01/2021 CC1551- Web Technologies End Term Examination Jan 2020

39

The practice of creating objects based on predefined classes is often referred to


as
(1 Point)

class instantiation

object creation

class creation

object instantiation

40

A Namespace in XML is used for


(1 Point)

is a querying language

provides the spaces in the names

none of these

distinguishes one XML vocabulary from another

41

Which of the following CSS Property sets the stacking order of positioned
elements?
(1 Point)

y-index

z-index

https://forms.office.com/Pages/ResponsePage.aspx?id=3S8oJwtM-026kSKM2D_fcShSlO6Hg81HoSyJRML7B8lUMjFMNEM3VU5CQ0JNVTFIME9… 18/20
19/01/2021 CC1551- Web Technologies End Term Examination Jan 2020

all of the mentioned

x-index

42

If the following piece of JavaScript code is executed, will it work if not, what
kind of possible error can occur?
1. function fun(o)
2. {
3. for(;o.next; oo =o.next);
4. return o;
5. }
(1 Point)

No, it will produce a runtime error with the message "Cannot use Linked List"

No, this will not iterate at all

No, it will throw an exception as only numeric's can be used in a for loop

Yes, it will work fine

43

Which of the following property defines the resampling method to use when
stretching images?
(1 Point)

layout

none of the mentioned

image-rendering

image-mode

https://forms.office.com/Pages/ResponsePage.aspx?id=3S8oJwtM-026kSKM2D_fcShSlO6Hg81HoSyJRML7B8lUMjFMNEM3VU5CQ0JNVTFIME9… 19/20
19/01/2021 CC1551- Web Technologies End Term Examination Jan 2020

44

XSLT is
(1 Point)

none of these

an extensible stylesheet language and is used for formatting

used for session tracking in XML

an extended stylesheet language is used for formatting

Submit

This content is created by the owner of the form. The data you submit will be sent to the form owner. Microsoft is not
responsible for the privacy or security practices of its customers, including those of this form owner. Never give out your
password.

Powered by Microsoft Forms | Privacy and cookies | Terms of use

https://forms.office.com/Pages/ResponsePage.aspx?id=3S8oJwtM-026kSKM2D_fcShSlO6Hg81HoSyJRML7B8lUMjFMNEM3VU5CQ0JNVTFIME9… 20/20

You might also like