• Complain

Lacanienta - PCAP-31-03 Practice Exam: PCAP – Certified Associate in Python Programming Certification

Here you can read online Lacanienta - PCAP-31-03 Practice Exam: PCAP – Certified Associate in Python Programming Certification full text of the book (entire story) in english for free. Download pdf and epub, get meaning, cover and reviews about this ebook. year: 2021, genre: Computer. Description of the work, (preface) as well as reviews are available. Best literature library LitArk.com created for fans of good reading and offers a wide selection of genres:

Romance novel Science fiction Adventure Detective Science History Home and family Prose Art Politics Computer Non-fiction Religion Business Children Humor

Choose a favorite category and find really read worthwhile books. Enjoy immersion in the world of imagination, feel the emotions of the characters or learn something new for yourself, make an fascinating discovery.

No cover
  • Book:
    PCAP-31-03 Practice Exam: PCAP – Certified Associate in Python Programming Certification
  • Author:
  • Genre:
  • Year:
    2021
  • Rating:
    4 / 5
  • Favourites:
    Add to favourites
  • Your mark:
    • 80
    • 1
    • 2
    • 3
    • 4
    • 5

PCAP-31-03 Practice Exam: PCAP – Certified Associate in Python Programming Certification: summary, description and annotation

We offer to read an annotation, description, summary or preface (depends on what the author of the book "PCAP-31-03 Practice Exam: PCAP – Certified Associate in Python Programming Certification" wrote himself). If you haven't found the necessary information about the book — write in the comments, we will try to find it.

Lacanienta: author's other books


Who wrote PCAP-31-03 Practice Exam: PCAP – Certified Associate in Python Programming Certification? Find out the surname, the name of the author of the book and a list of all author's works by series.

PCAP-31-03 Practice Exam: PCAP – Certified Associate in Python Programming Certification — read online for free the complete book (whole text) full work

Below is the text of the book, divided by pages. System saving the place of the last page read, allows you to conveniently read the book "PCAP-31-03 Practice Exam: PCAP – Certified Associate in Python Programming Certification" online for free, without having to search again every time where you left off. Put a bookmark, and you can go to the page where you finished reading at any time.

Light

Font size:

Reset

Interval:

Bookmark:

Make
Exam block #1: Modules and Packages (12%)
Objectives covered by the block (6 items) * import variants ; advanced qualifying for nested modules What is the output of the following code if spam.py is run? # spam.py
print( "spam" , end= ' ' )
import ham
# ham.py
import eggs
print( "ham" , end= ' ' )
# eggs.py
print( "eggs" , end= ' ' )
( ) Syntax Error ( ) spam eggs ham ( ) spam ham ( ) eggs ham spam ( ) spam ham eggs How do you call the function ham() saved as spam.py below?
def ham ():
print( "Hello World" )
[ ] import spam; ham() [ ] import spam.ham; ham() [ ] import spam; spam.ham() [ ] from spam import ham; ham() [ ] import ham from spam; ham() * import variants; advanced qualifying for nested modules Given the following package layout
package/
subpackage1/
__init__.py
moduleX.py
moduleY.py
subpackage2/
moduleZ.py
moduleA.py
Select all option(s) containing valid relative imports called from __init__.py [ ] from .moduleY import spam
[ ] from .moduleY import spam as ham
[ ] from ..subpackage1 import moduleY
[ ] from ..subpackage2.moduleZ import eggs
[ ] from ..moduleA import foo How will you shorten the function call to spam() defined inside packageA.subpackageB.subpackageC.moduleD? [ ] import packageA.subpackageB.subpackageC.moduleD
[ ] import packageA.subpackageB.subpackageC.moduleD as p
[ ] import packageA.subpackageB.subpackageC.moduleD alias p
[ ] from packageA.subpackageB.subpackageC.moduleD import *
[ ] from packageA.subpackageB.subpackageC.moduleD import spam
[ ] from packageA.subpackageB.subpackageC.moduleD import spam as s
[ ] from packageA.subpackageB.subpackageC.moduleD import spam alias s * dir() ; sys.path variable Select all valid parameters to function dir() [ ] No parameter [ ] Object [ ] [ ] None Select all valid option(s) about the result of dir() [ ] A list of filenames inside the directory
[ ] A list of the module's attribute
[ ] A list of names of class attributes
[ ] A list of names of object attributes
[ ] A list of names of the base class attributes
* dir(); sys.path variable Select all valid option(s) about sys.path [ ] sys.path is a string that specifies the path where Python is installed
[ ] sys.path is a string that specifies the path of the compiled Python bytecode
[ ] sys.path is a list of strings that specifies the search path for modules
[ ] A program is free to modify sys.path for its own purpose.
* math: ceil() , floor(), trunc(), factorial(), hypot(), sqrt(); random: random(), seed(), choice(), sample() What is the output of the following code?
>>> math.ceil( -1.1 )
( ) -1 ( ) -1.0 ( ) -2 ( ) -2.0 * math: ceil(), floor() , trunc(), factorial(), hypot(), sqrt(); random: random(), seed(), choice(), sample() What is the output of the following code?
>>> math.floor( -1.1 )
( ) -1 ( ) -1.0 ( ) -2 ( ) -2.0 * math: ceil(), floor(), trunc(), factorial() , hypot(), sqrt(); random: random(), seed(), choice(), sample() What is the output of the following code?
>>> math.factorial( 3.0 ))
( ) ( ) 6.0 ( ) TypeError: type float doesn't define __factorial__ method ( ) TypeError: factorial() takes 2 arguments What is the output of the following code?
>>> math.factorial( -3.0 )
( ) -6
( ) -6.0 ( ) TypeError: type float doesn't define __factorial__ method ( ) ValueError: factorial() not defined for negative values * math: ceil(), floor(), trunc(), factorial(), hypot() , sqrt(); random: random(), seed(), choice(), sample() What is the output of the following code?
>>> math.hypot( )
( ) 3.6055512754639896 ( ) 2.0 ( ) TypeError: type int doesn't define __hypot__ method ( ) TypeError: hypot() takes 2 arguments * math: ceil(), floor(), trunc(), factorial(), hypot(), sqrt() ; random: random(), seed(), choice(), sample() What is the output of the following code?
>>> math.sqrt( )
( ) 0.5 ( ) ( ) 1.0 ( ) TypeError: type int doesn't define __sqrt__ method * math: ceil(), floor(), trunc(), factorial(), hypot(), sqrt(); random: random() , seed(), choice(), sample() Select all option(s) which returns a random floating number between 0 and 1? ( ) math.random() ( ) math.random(1.0) ( ) random.random() ( ) random.random(1.0) Select all option(s) which returns a random number between 0 and 100? ( ) random.random(100)
( ) random.random(0, 100)
( ) random.random()*100
( ) random.random(100.0) * math: ceil(), floor(), trunc(), factorial(), hypot(), sqrt(); random: random(), seed() , choice(), sample() What can be the possible output of the following code?
random.seed( , )
print(random.random())
( ) 3.6055512754639896 ( ) 0.5714025946899135 ( ) AttributeError: module 'random' has no attribute 'seed' ( ) TypeError: seed() takes 1 argument * math: ceil(), floor(), trunc(), factorial(), hypot(), sqrt(); random: random(), seed(), choice() , sample() Select all option(s) to properly call the choice() and/or choices() function? [ ] random.choice("spam", "ham", "eggs") [ ] random.choice(["spam", "ham", "eggs"]) [ ] random.choice({"spam", "ham", "eggs"}) [ ] random.choices(["spam", "ham", "eggs"]) [ ] random.choices(["spam", "ham", "eggs"], weights = [10, 1, 1], k = 14) * math: ceil(), floor(), trunc(), factorial(), hypot(), sqrt(); random: random(), seed(), choice(), sample() What can be the possible output of the following code?
>>> random.sample([ "spam" , "ham" , "eggs" ], k = )
( ) spam ( ) [spam] ( ) TypeError: sample() got an unexpected keyword argument 'k' ( ) TypeError: sample() takes 1 argument * platform: platform() , machine(), processor(), system(), version(), python_implementation(), python_version_tuple() Select all option(s) to properly call the platform() function? [ ] system.platform() [ ] platform.platform() [ ] system.platform(aliased=0, terse=0) [ ] platform.platform(alias=0, version=0) [ ] platform.platform(aliased=0, terse=0) * platform: platform(), machine() , processor(), system(), version(), python_implementation(), python_version_tuple() Select all option(s) to properly call the machine() function? [ ] system . machine() [ ] platform . machine() [ ] system . machine(aliased=0) [ ] platform . machin e( terse=0) [ ] platform . [ ] Possible return values are CPython , IronPython , Jython , PyPy . * platform: platform(), machine(), processor(), system(), version() , python_implementation(), python_version_tuple() Select all option(s) to properly call the version() function? [ ] system.version() [ ] platform.version() [ ] system.version(aliased=0) [ ] platform.version(terse=0) [ ] platform.version(None) What is the datatype of the return value of the function platform.version()? ( ) int ( ) float ( ) str ( ) array * platform: platform(), machine(), processor(), system(), version(), python_implementation() , python_version_tuple() Select all option(s) to properly call the python_implementation() function? [ ] system.python_implementation() [ ] platform.python_implementation() [ ] system.python_implementation(aliased=0) [ ] platform.python_implementation(terse=0) [ ] platform.python_implementation(None) Select all option(s) about the python_implementation() that is TRUE? [ ] python_implementation() returns the OS hosting Python [ ] python_implementation() returns the execution environment of Python [ ] Possible return values are Linux , Darwin , Java , Windows or an empty string if it can't be determined. [ ] Possible return values are CPython , IronPython , Jython , PyPy . * platform: platform(), machine(), processor(), system(), version(), python_implementation(), python_version_tuple() Select all option(s) to properly call the python_version_tuple() function? [ ] system.python_version_tuple() [ ] platform.python_version_tuple() [ ] system.python_version_tuple(aliased=0) [ ] platform.python_version_tuple(terse=0) [ ] platform.python_version_tuple(None) * idea: __pycache__ , __name__, public variables, __init__.py Which of the statements below is valid? [ ] Python is interpreted therefore it never compiles the py files.
Next page
Light

Font size:

Reset

Interval:

Bookmark:

Make

Similar books «PCAP-31-03 Practice Exam: PCAP – Certified Associate in Python Programming Certification»

Look at similar books to PCAP-31-03 Practice Exam: PCAP – Certified Associate in Python Programming Certification. We have selected literature similar in name and meaning in the hope of providing readers with more options to find new, interesting, not yet read works.


Reviews about «PCAP-31-03 Practice Exam: PCAP – Certified Associate in Python Programming Certification»

Discussion, reviews of the book PCAP-31-03 Practice Exam: PCAP – Certified Associate in Python Programming Certification and just readers' own opinions. Leave your comments, write what you think about the work, its meaning or the main characters. Specify what exactly you liked and what you didn't like, and why you think so.