Google News
logo
CherryPy - Quiz(MCQ)

CherryPy is a pythonic, object-oriented web framework : CherryPy allows developers to build web applications in much the same way they would build any other object-oriented Python program. This results in smaller source code developed in less time.

CherryPy is now more than ten years old and it is has proven to be very fast and stable. It is being used in production by many sites, from the simplest to the most demanding.

A)
Remi Delon
B)
Rob Pike
C)
Steve Jobs
D)
Richard Stallman

Correct Answer :   Remi Delon


Explanation : One of the goals of the project founder, Remi Delon, was to make CherryPy as pythonic as possible. This allows the developer to use the framework as any regular Python module and to forget (from a technical point of view) that the application is for the web.

A)
August 1995
B)
January 2000
C)
June 2002
D)
March 2003

Correct Answer :   June 2002


Explanation : CherryPy is a web framework of Python which provides a friendly interface to the HTTP protocol for Python developers. It is also called a web application library.

Remi Delon released the first version of CherryPy in late June 2002. This was the starting point of a successful Python web library. Remi is a French hacker who has trusted Python for being one of the greatest alternatives for web application development.

A)
C
B)
Python
C)
Java
D)
PHP

Correct Answer :   Python


Explanation : CherryPy is a Python web framework.

A)
CherryPy was close to the model-view-controller pattern
B)
CherryPy can map a URL and its query string into a Python method call
C)
A CherryPy class has to be processed and compiled by the CherryPy engine
D)
All of the above

Correct Answer :   All of the above


Explanation : All of the above are true regarding CherryPy.

A)
True
B)
False
C)
Can Not Say
D)
None of the above

Correct Answer :   True


Explanation : True, CherryPy comes with its own web (HTTP) server.

A)
Django
B)
Pyramid
C)
BlueBream
D)
All of the above

Correct Answer :   All of the above


Explanation : Django, Bottle, Pyramid, BlueBream, TurboGears, ActiveState Platform.

A)
Netflix
B)
Hulu
C)
Both (A) and (B)
D)
Amazon Prime

Correct Answer :   Both (A) and (B)

A)
Yes
B)
No
C)
Can Not Say
D)
None of the above

Correct Answer :   Yes

A)
Yes
B)
No
C)
Can Not Say
D)
None of the above

Correct Answer :   Yes

A)
Gmail
B)
YouTube
C)
Google Maps
D)
All of the above

Correct Answer :   All of the above


Explanation : Google Maps, Gmail, YouTube, and Facebook are examples of AJAX applications.

A)
Serialize
B)
write
C)
Generate
D)
None of the above

Correct Answer :   write


Explanation : With the Write command, a file object is created with the output content.

A)
cherryPy.server.start()
B)
cherryPy.client.start()
C)
cherryPy.server.quickstart()
D)
cherryPy.client.quickstart()

Correct Answer :   cherryPy.server.quickstart()


Explanation : To start the web server, a user must make the following call : cherryPy.server.quickstart()

A)
Simplicity
B)
Open-source
C)
Cost effective
D)
All of the above

Correct Answer :   All of the above


Explanation : All of the above are the strengths of Cherrypy.

A)
status code (100)
B)
status code (200)
C)
status code (400)
D)
status code (505)

Correct Answer :   status code (100)


Explanation : CherryPy can handle response status code (100) with the support of clients.

A)
0
B)
1
C)
2
D)
3

Correct Answer :   2


Explanation : CherryPy supports requests in two distinct ways − If-Modified-Since and If-Unmodified-Since headers and sends responses as per the requests accordingly.

A)
True
B)
False
C)
Can Not Say
D)
None of the above

Correct Answer :   True


Explanation : True, CherryPy is designed based on the multithreading concept.

A)
Yes
B)
No
C)
Can Not Say
D)
None of the above

Correct Answer :   Yes


Explanation : Yes, CherryPy allows us to perform CRUD operations and we can also manage the project from anywhere.

A)
Yes
B)
No
C)
Can Not Say
D)
None of the above

Correct Answer :   Yes


Explanation : Yes, CherryPy follows the MVC architecture.

A)
write
B)
Generate
C)
Serialize
D)
None of the above

Correct Answer :   Generate


Explanation : The generate command returns the output content as an iterator.

A)
write
B)
Generate
C)
Serialize
D)
None of the above

Correct Answer :   Serialize


Explanation : Serialize function returns a string representation of the output content.

A)
Network layer
B)
Transport layer
C)
Application-layer
D)
Presentation layer

Correct Answer :   Presentation layer


Explanation : As part of its role, the Presentation Layer ensures that the communication passing through it is directed toward the intended audience.

A)
Network level protocol
B)
Transport level protocol
C)
Application-level protocol
D)
None of the above

Correct Answer :   Application-level protocol


Explanation : Atom publishing protocol is an application-level protocol.

A)
Encoding
B)
Decoding
C)
Caching
D)
Authentication

Correct Answer :   Decoding


Explanation : The purpose of this tool is to decode the incoming request parameters.

A)
The purpose of this tool is to decode the incoming request parameters
B)
The purpose of this tool is to provide memory caching of CherryPy generated content
C)
The purpose of this tool is to provide basic authentication to the application designed in the application.
D)
None of the above

Correct Answer :   The purpose of this tool is to provide basic authentication to the application designed in the application.


Explanation : The purpose of this tool is to provide basic authentication to the application designed in the application.

A)
cherrypy.client
B)
cherrypy.engine
C)
cherrypy.tools
D)
cherrypy.server

Correct Answer :   cherrypy.engine


Explanation : cherrypy.engine : It controls process startup/teardown and event handling.

A)
Yes
B)
No
C)
Can Not Say
D)
None of the above

Correct Answer :   Yes

A)
Using a Tarball
B)
Using Subversion
C)
Using easy_install
D)
All of the above

Correct Answer :   All of the above


Explanation : Using any of the following ways you can install CherryPy : Using a Tarball, using easy_install, Using Subversion.

A)
Tarball
B)
Directory
C)
Subversion
D)
All of the above

Correct Answer :   Tarball


Explanation : A Tarball is a compressed archive of files or a directory.

A)
To fix bugs in the previous release.
B)
When the developer is working on CherryPy.
C)
When a branch from the main branch in the versioning control repository is requested by the user.
D)
All of the above

Correct Answer :   All of the above


Explanation : It is suggested to install CherryPy using Subversion, in the following situations:

* To fix bugs in the previous release.
* When the developer is working on CherryPy.
* When a branch from the main branch in the versioning control repository is requested by the user.

A)
Web server
B)
Application
C)
Application server
D)
Web application server

Correct Answer :   Application server


Explanation : The application server is the component that facilitates one or more applications.

A)
Web server
B)
Application
C)
Web application server
D)
Application server

Correct Answer :   Web application server


Explanation : A web application server is a hybrid of a web server and an application server.

A)
A protocol that allows the publishing and editing of web resources.
B)
A protocol that performs a set of operations between APP service and user agent.
C)
All of the above
D)
None of the above

Correct Answer :   All of the above


Explanation : Atom publishing protocol is a protocol that allows the publishing and editing of web resources, also it performs a set of operations between the APP service and user agent.

A)
Atom publishing protocol
B)
Application process protocol
C)
Application publishing protocol
D)
None of the above

Correct Answer :   Atom publishing protocol

A)
Web server
B)
Application
C)
Web application server
D)
Application server

Correct Answer :   Web server


Explanation : A web server is a connector for something like the HTTP protocol.

A)
Web server
B)
Application
C)
Web application server
D)
Application server

Correct Answer :   Application


Explanation : An application is a piece of software that involves the collection of data.

A)
Web server
B)
Application
C)
Web application server
D)
Application server

Correct Answer :   Web server


Explanation : The web server keeps track of requests and responses.

A)
Controlling the CherryPy process.
B)
Managing the CherryPy process.
C)
Creation of request and response objects.
D)
All of the above

Correct Answer :   All of the above


Explanation : Following are the responsibilities of the internal engine Cherry :

* Controlling the CherryPy process.
* Managing the CherryPy process.
* Creation of request and response objects.
* Management of request and response objects.

A)
GET
B)
PUT
C)
HEAD
D)
POST

Correct Answer :   HEAD

A)
Atom Put Protocol
B)
Atom Publishing Protocol
C)
Atom Post Protocol
D)
Atom Publishing Process

Correct Answer :   Atom Publishing Protocol


Explanation : App stands for Atom Publishing Protocol.

A)
PUT
B)
REMOVE
C)
DELETE
D)
OPTIONS

Correct Answer :   DELETE


Explanation : DELETE: Requests the server to remove the resource identified by that URI.

A)
True
B)
False
C)
Can Not Say
D)
None of the above

Correct Answer :   True


Explanation : True, The Atom Publishing Protocol defines a set of operations between an APP service and a user-agent using HTTP.

42 .
_________ is a simple template engine which includes the name of the template to be processed (which is mandatory) and input of the data to be passed when the template is rendered.
A)
Cpl
B)
Kid
C)
App
D)
Atom

Correct Answer :   Kid


Explaination : Kid is a simple template engine which includes the name of the template to be processed (which is mandatory) and input of the data to be passed when the template is rendered.

A)
Yes
B)
No
C)
Can Not Say
D)
None of the above

Correct Answer :   Yes


Explanation : Yes, CherryPy has its configuration system.

A)
HTTP
B)
HTTP/1.0
C)
HTTP/1.1
D)
None of the above

Correct Answer :   HTTP/1.1


Explanation : If a client states that it supports HTTP/1.1, it must include a header field in any request by using the protocol version.

A)
CherryPy.request
B)
CherryPy.response
C)
CherryPy.client
D)
Both (A) and (B)

Correct Answer :   Both (A) and (B)


Explanation : CherryPy.response and CherryPy.request are the thread data containers in CherryPy.

A)
Single threading
B)
Multithreading
C)
User-level threading
D)
All of the above

Correct Answer :   Multithreading


Explanation : CherryPy is centered around the concept of multithreading.

47 .
In which of the following HTTP authentications, the user submits the credential in clear text with minimal authentication, thus any potential hacker who sees the request may read the password?
A)
Basic
B)
Digest
C)
Can Not Say
D)
None of the above

Correct Answer :   Basic


Explaination : In Basic authentication, the user submits the credential in clear text with minimal authentication, thus any potential hacker who sees the request may read the password.

A)
PUT
B)
GET
C)
POST
D)
HEAD

Correct Answer :   PUT


Explanation : PUT method specifies that a resource enclosed in the request body should be replaced by the one requested.

A)
PUT
B)
GET
C)
HEAD
D)
POST

Correct Answer :   POST


Explanation : In the POST, HTTP method a request is made to the server to create a new resource based on the data contained in the request body.

A)
Bad request
B)
Unauthorized access
C)
Unauthorized request
D)
None of the above

Correct Answer :   Unauthorized request


Explanation : ERROR CODE 403 in CherryPy indicates an unauthorized request.

A)
Bad request
B)
Unauthorized access
C)
Unauthorized request
D)
None of the above

Correct Answer :   Bad request


Explanation : ERROR CODE 400 in CherryPy indicates a bad request.

A)
Yes
B)
No
C)
Can Not Say
D)
None of the above

Correct Answer :   Yes


Explanation : Yes, CherryPy supports encapsulation.

A)
Encapsulation
B)
Authorization
C)
Authentication
D)
None of the above

Correct Answer :   Authorization


Explanation : The authorization process ensures the URI process remains sane.

A)
Authorization
B)
Authentication
C)
Can Not Say
D)
None of the above

Correct Answer :   Authentication


Explanation : Authentication aids in the validation of the users with whom we engage.

A)
cherrypy.server
B)
cherrypy.engine
C)
Both (A) and (B)
D)
cherrypy.tools.

Correct Answer :   cherrypy.tools.


Explanation : Cherrypy.tools is a collection of utilities that are unrelated to the execution of an HTTP request.

A)
cherrypy.tools.
B)
cherrypy.engine
C)
cherrypy.server
D)
None of the above

Correct Answer :   cherrypy.server


Explanation : Cherrypy.server sets up and manages the WSGI or HTTP server.

A)
3
B)
4
C)
5
D)
6

Correct Answer :   3


Explanation : Basic authentication tools have three arguments: Realm, Users, and encrypt.

A)
get
B)
Users
C)
User_get
D)
Get_users

Correct Answer :   Get_users


Explanation : Get_users returns a hard-coded dictionary and also fetches the values from databases.

A)
Caching tool
B)
Decoding tool
C)
Basic authentication tool
D)
None of the above

Correct Answer :   Basic authentication tool


Explanation : Basic authentication tool's objective is to provide basic authentication to the application's desired purposes.

A)
Decoding tool
B)
Caching tool
C)
Basic authentication tool
D)
None of the above

Correct Answer :   Caching tool


Explanation : Caching tool This tool's objective is to offer memory caching of CherryPy-produced material.

A)
2
B)
3
C)
4
D)
5

Correct Answer :   2


Explanation : Caching tools have two arguments: invalid_methods, and cache_class.

A)
Caching tool
B)
Decoding tool
C)
Basic authentication tool
D)
None of the above

Correct Answer :   Decoding tool


Explanation : Decoding tool's mission is to decipher the receiving response parameters.

A)
5
B)
4
C)
3
D)
2

Correct Answer :   2


Explanation : Decoding tools have two arguments encoding, and default_encoding.

A)
Server.py
B)
Model.py
C)
Config.py
D)
Controllers.py

Correct Answer :   Controllers.py


Explanation : All of the objects that will be mounted on the CherryPy.tree are implemented in controllers.py.

65 .
A)
Uniform Resource Name
B)
Uniform Reserve Name
C)
Unified Resource Nomenclature
D)
Uniform Reverce Name

Correct Answer :   Uniform Resource Name

A)
0
B)
1
C)
2
D)
3

Correct Answer :   2


Explanation : URI has two subsets: URL and URN.

A)
Uniform Resource Locator
B)
Uniform Resource Identifiers
C)
Hypertext Transfer Protocol
D)
Application Programming Interface

Correct Answer :   Uniform Resource Identifiers


Explanation : If the REST infrastructure is built on the HTTP foundation, these IDs are known as Uniform Resource Identifiers (URIs).

A)
Model.py
B)
Config.py
C)
Server.py
D)
Controllers.py

Correct Answer :   Model.py


Explanation : Model.py file interacts directly with the database to provide various services or to store permanent data.

A)
Config.py
B)
Model.py
C)
Controllers.py
D)
Server.py

Correct Answer :   Server.py


Explanation : Model.py file interacts directly with the database to provide various services or to store permanent data.

A)
View
B)
Static
C)
Server.py
D)
Controllers.py

Correct Answer :   Static


Explanation : Static files include all the CSS and image files.

A)
View
B)
Static
C)
Server.py
D)
Controllers.py

Correct Answer :   View


Explanation : View files include all the template files for a given application.

A)
Hypertext Transfer Protocol
B)
Application Programming Interface
C)
Representational state transfer
D)
None of the above

Correct Answer :   Representational state transfer


Explanation : REST is a sort of remote access protocol in which state is sent from client to server and may be used to alter state rather than invoking remote operations.

A)
Recognize State Transfer
B)
Representational State Transfer
C)
Represent Electronic State Transfer
D)
None of the above

Correct Answer :   Representational State Transfer


Explanation : REST stands for Representational State Transfer.

A)
Get()
B)
Users()
C)
Initiate()
D)
Index()

Correct Answer :   Index()


Explanation : The index function is a default function that is loaded initially when a certain controller is called.