Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

A(n) _____ allows you to treat a related group of C# commands as a single unit. statement variable function event Flag this Question Question 2

A(n) _____ allows you to treat a related group of C# commands as a single unit.

statement

variable

function

event

Flag this Question

Question 2

______ are values or variables passed to the to be assigned to the function parameters.

Methods

Arguments

Solutions

Integers

Question 3

A variable that is declared outside a function in a code declaration block is called a _____ variable.

local

class

program

global

Question 4

A local variable must be declared _____.

before a function

after a function

within the braces of a function definition

with the local keyword

Question 5

If a client submits a form with the get method, the forms name=value pairs are stored in the _____ collection of the Request object.

Form

Get

QueryString

Cookies

Question 6

Which of the following is the correct syntax for an if statement?

if (myVariable == 10); Response.Write("Your variable is equal to 10.");

if myVariable == 10 Response.Write("Your variable is equal to 10.");

if (myVariable == 10) Response.Write("Your variable is equal to 10.");

if (myVariable == 10), Response.Write("Your variable is equal to 10.");

Question 7

An if statement can include multiple statements provided that they _____.

execute after the if statements closing semicolon

are not contained within a command block

do not include other if statements

are contained within a command block

Question 8

Which is the correct syntax for an else clause?

else (Response.Write("Printed from an else clause.");

else Response.Write("Printed from an else clause.");

else "Response.Write('Printed from an else clause.')";

else; Response.Write("Printed from an else clause.");

Question 9

The switch statement controls program flow by executing a specific set of statements, depending on _____.

the result of an if...else statement

the version of C# being executed

whether an if statement executes from within a function

the value returned by a conditional expression

Question 10

When the value returned by a switch statement expression does not match a case label, the statements within the _____ label execute.

exception

else

error

default

Question 11

You can exit a switch statement using a(n) _____ statement.

break

end

quit

complete

Question 12

Each repetition of a looping statement is called a(n) _____.

recurrence

iteration

duplication

reexecution

Question 13

Which of the following is the correct syntax for a while statement?

while (i <= 5, ++i) { Response.Write("

i

"); }

while (i <= 5) { Response.Write("

i

"); ++i; }

while (i <= 5); Response.Write("

i

"); ++i;

while (i <= 5; Response.Write("

i

")) { ++i; }

Question 14

Which of the following is the correct syntax for a for statement?

for (var i = 0; i < 10; ++i) Response.Write("Printed from a for statement.");

for (var i = 0, i < 10, ++i) Response.Write("Printed from a for statement.");

for { Response.Write("Printed from a for statement."); } while (var i = 0; i < 10; ++i)

for (var i = 0; i < 10); Response.Write("Printed from a for statement.");

Question 15

When is a for statement initialization expression executed?

when the for statement begins executing

with each repetition of the for statement

when the counter variable increments

when the for statement ends

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Semantics Of A Networked World Semantics For Grid Databases First International Ifip Conference Icsnw 2004 Paris France June 2004 Revised Selected Papers Lncs 3226

Authors: Mokrane Bouzeghoub ,Carole Goble ,Vipul Kashyap ,Stefano Spaccapietra

2004 Edition

3540236090, 978-3540236092

More Books

Students also viewed these Databases questions