CS 3305: WEB PROGRAMMING 2
What is the name given to Internet technologies supporting user collaboration and data exchange?
Select one:
- Web 2.0
- SQL Server
- Mobile technology
- Android
The correct answer is: Web 2.0
Question 2
What are advantages of scripted applications over compiled applications? Choose all that apply.
Select one or more:
- performance
- readability
- maintainability
- functionality
The correct answer is: readability, maintainability
Question 3
What are examples of a scripted language? Choose all that apply.
Select one or more:
- C++
- PHP
- Perl
- Objective-C
The correct answer is: PHP, Perl
Question 4
Which database in the list is Open Source?
Select one:
- SQL Server
- MySQL
- Oracle
- Apache
The correct answer is: MySQL
Question 5
What is a good example of static Internet content?
Select one:
- CNN news page
- Yahoo home page
- Facebook Wall
- None of the above
The correct answer is: None of the above
Question 6
True or False: Most of the web sites today are Web 2.0.
Select one:
True
False
The correct answer is 'True'.
Question 7
True or False: Server-side programming allows users to login to web sites and generate content each time the page is visited.
Select one:
True
False
The correct answer is 'True'.
Question 8
True or False: Server-side programming uses some of the same languages as client-side (workstation) programming.
Select one:
True
False
The correct answer is 'True'.
Question 9
Select an example of a server-side programming language:
Select one:
- JavaScript
- Perl
- HTML
- CSS
The correct answer is: Perl
Question 10
The speed of writing server code is increased when:
Select one:
- The developer receives immediate upon making changes
- The software is compiled before it is executed
- The developer uses discussion forums to debug code
- The software interpreted and error reporting is turned off
The correct answer is: The developer receives immediate upon making changes
What program can be used on a Windows computer to access a command prompt on a Unix/Linux server?
Select one:
- putty.exe
- SQL Server
- cmd
- Internet Explorer
The correct answer is: putty.exe
Question 2
What commands can be used on a Linux server?
Select one or more:
- putty.exe
- ls
- make
- Click on Start button
The correct answer is: ls, make
Question 3
What are examples of a scripted language? Choose all that apply.
Select one or more:
- C++
- PHP
- Perl
- Objective-C
The correct answer is: PHP, Perl
Question 4
Which system is an example of an Open Source database?
Select one:
- SQL Server
- MySQL
- Oracle
- Apache
The correct answer is: MySQL
Question 5
What Linux command downloads source code?
Select one:
- mput
- get
- Internet Explorer
- wget
The correct answer is: wget
Question 6
True or False: Source code can be executed.
Select one:
True
False
The correct answer is 'False'.
Question 7
True or False: Software can be compiled at the command prompt.
Select one:
True
False
The correct answer is 'True'.
Question 8
True or False: Apache is called httpd on a Linux server.
Select one:
True
False
The correct answer is 'True'.
Question 9
What is the most common extension for a source code package?
Select one:
- .zip
- .tgz
- .txt
- .os
The correct answer is: .tgz
Question 10
What command extracts a tarball archive file?
Select one:
- tar -xzvf
- tar -czvf
- tar -out
- tar -v
The correct answer is: tar –xzvf
What does PHP stand for?
Select one:
- PHP: Hypertext Preprocessor
- Private Home Page
- Personal Home Page
- Personal Hypertext Processor
The correct answer is: PHP: Hypertext Preprocessor
Question 2
PHP server scripts are surrounded by what delimiters?
Select one:
- <&></&>
- <?PHP ?>
- <?PHP > </?>
- <script></script>
The correct answer is: <?PHP ?>
Question 3
How do you write "Hello World" in PHP?
Select one:
- Document.Write("Hello World");
- echo “Hello World”;
- “Hello World”
- system.out.println(“Hello World”);
Your answer is incorrect.
The correct answer is: echo “Hello World”;
Question 4
All variables in PHP start with which symbol?
Select one:
- &
- $
- !
- --
The correct answer is: $
Question 5
What is the correct way to end a PHP statement?
Select one:
- </php>
- :
- .
- ;
The correct answer is: ;
Question 6
True or False:The PHP syntax is similar to many languages including C++ and Java, which makes it easy to learn for programmers:
Select one:
True
False
The correct answer is 'True'.
Question 7
True or False: When using the POST method, variables are displayed in the URL.
Select one:
True
False
The correct answer is 'False'.
Question 8
True or False: In PHP you can use both single quotes ( ' ' ) and double quotes ( " " ) for strings.
Select one:
True
False
The correct answer is 'True'.
Question 9
The PHP syntax is most similar to:
Select one:
- JavaScript
- Perl and C
- HTML
- CSS
The correct answer is: Perl and C
Question 10
How do you get information from a form that is submitted using the "get" method?
Select one:
- $_GET[];
- Request.Form;
- Request.QueryString;
- .getParameter();
The correct answer is: $_GET[];
Question 11
What is the correct way to create a function in PHP?
Select one:
- new_function myFunction()
- function myFunction()
- create myFunction()
- create myFunction(function)
The correct answer is: function myFunction()
Question 12
What is the correct way to add 1 to the $count variable?
Select one:
- $count =+1
- ++count
- $count++;
- count++;
The correct answer is: $count++;
Question 13
What is a correct way to add a comment in PHP?
Select one:
- <comment> </comment>
- <!-- -->
- *\ *\
- /* */
The correct answer is: /* */
Question 14
Identify a valid PHP variable:
Select one:
- x
- x$
- $x
- $x$
The correct answer is: $x
Question 15
PHP script can perform the following functions:
Select one:
- Generate an email to one or more receipients.
- Insert data into a database
- Display data from a database
- All of the above
The correct answer is: All of the above