Download Microsoft.98-381.PracticeTest.2018-08-10.20q.vcex

Download Exam

File Info

Exam Introduction to Programming Using Python
Number 98-381
File Name Microsoft.98-381.PracticeTest.2018-08-10.20q.vcex
Size 769 KB
Posted Aug 10, 2018
Download Microsoft.98-381.PracticeTest.2018-08-10.20q.vcex

How to open VCEX & EXAM Files?

Files with VCEX & EXAM extensions can be opened by ProfExam Simulator.

Purchase

Coupon: MASTEREXAM
With discount: 20%






Demo Questions

Question 1

The ABC company has hired you as an intern on the coding team that creates e-commerce applications. 
You must write a script that asks the user for a value. The value must be used as a whole number in a calculation, even if the user enters a decimal value. 
You need to write the code to meet the requirements. 
Which code segment should you use? 


  1. totalItems = input(“How many items would you like?”)
  2. totalItems = float(input(“How many items would you like?”))
  3. totalItems = str(input(“How many items would you like?”))
  4. totalItems = int(input(“How many items would you like?”))
Correct answer: B
Explanation:
References: http://anh.cs.luc.edu/python/hands-on/3.1/handsonHtml/io.html
References: http://anh.cs.luc.edu/python/hands-on/3.1/handsonHtml/io.html



Question 2

During school holidays, you volunteer to explain some basic programming concepts to younger siblings. 
You want to introduce the concept of data types in Python. You create the following three code segments:
  
You need to evaluate the code segments. 
For each of the following statements, select Yes if the statement is true. Otherwise, select No. 
NOTE: Each correct selection is worth one point.


Correct answer: To work with this question, an Exam Simulator is required.
Explanation:
Code Segment 1: You cannot convert str to int. x1 = “2” is a string. Therefore code will produce an error.Code Segment 2: b = 1.5, which is a float.Code Segment 3: c = 2.5, which is a float, not an int.References: https://www.w3resource.com/python/python-data-type.php
  • Code Segment 1: You cannot convert str to int. x1 = “2” is a string. Therefore code will produce an error.
  • Code Segment 2: b = 1.5, which is a float.
  • Code Segment 3: c = 2.5, which is a float, not an int.
References: https://www.w3resource.com/python/python-data-type.php



Question 3

The ABC company is converting an existing application to Python. You are creating documentation that will be used by several interns who are working on the team. 
You need to ensure that arithmetic expressions are coded correctly. 
What is the correct order of operations for the six classes of operations ordered from first to last in order of precedence? To answer, move all operations from the list of operations to the answer area and arrange them in the correct order.


Correct answer: To work with this question, an Exam Simulator is required.
Explanation:
References: http://www.mathcs.emory.edu/~valerie/courses/fall10/155/resources/op_precedence.html
References: http://www.mathcs.emory.edu/~valerie/courses/fall10/155/resources/op_precedence.html



Question 4

You are writing a Python program. The program collects customer data and stores it in a database. 
The program handles a wide variety of data.  
You need to ensure that the program handles the data correctly so that it can be stored in the database correctly. 
Match the data type to the code segment. To answer, drag the appropriate data type from the column on the left to its code segment on the right. Each data type may be used once, more than once, or not at all. 


Correct answer: To work with this question, an Exam Simulator is required.
Explanation:
References: https://www.w3resource.com/python/python-data-type.php
References: https://www.w3resource.com/python/python-data-type.php



Question 5

You are creating a Python program that shows a congratulation message to employees on their service anniversary. 
You need to calculate the number of years of service and print a congratulatory message. 
You have written the following code. Line numbers are included for reference only. 
  
You need to complete the program. 
Which code should you use at line 03?


  1. print(“Congratulations on” + (int(end)-int(start)) + “years of service!”)
  2. print(“Congratulations on” + str(int(end)-int(start)) + “years of service!”)
  3. print(“Congratulations on” + int(end - start) + “years of service!”)
  4. print(“Congratulations on” + str(end - start)) + “years of service!”)
Correct answer: B
Explanation:
int must be converted to string
int must be converted to string



Question 6

You are writing a Python program to perform arithmetic operations. 
You create the following code:
  
What is the result of each arithmetic expression? To answer, drag the appropriate expression from the column on the left to its result on the right. Each expression may be used once, more than once, or not at all. 


Correct answer: To work with this question, an Exam Simulator is required.
Explanation:
References: https://www.w3resource.com/python/python-operators.php
References: https://www.w3resource.com/python/python-operators.php



Question 7

You are writing a Python program that evaluates an arithmetic formula.  
The formula is described as b equals a multiplied by negative one, then raised to the second power, where a is the value that will be input and b is the result. 
You create the following code segment. Line numbers are included for reference only. 
  
You need to ensure that the result is correct. 
How should you complete the code on line 02? To answer, drag the appropriate code segment to the correct location. Each code segment may be used once, more than once, or not at all. You may need to drag the split bar between panes or scroll to view content. 
NOTE: Each correct selection is worth one point.


Correct answer: To work with this question, an Exam Simulator is required.



Question 8

Evaluate the following Python arithmetic expression:
  
What is the result?


  1. 3
  2. 13
  3. 15
  4. 69
Correct answer: C
Explanation:
References: http://www.mathcs.emory.edu/~valerie/courses/fall10/155/resources/op_precedence.html
References: http://www.mathcs.emory.edu/~valerie/courses/fall10/155/resources/op_precedence.html



Question 9

You develop a Python application for your company. 
A list named employees contains 200 employee names, the last five being company management. You need to slice the list to display all employees excluding management.  
Which two code segments should you use? Each correct answer presents a complete solution. (Choose two.)


  1. employees [1:-4]
  2. employees [:-5]
  3. employees [1:-5]
  4. employees [0:-4]
  5. employees [0:-5]
Correct answer: BE
Explanation:
References: https://www.w3resource.com/python/python-list.php#slice
References: https://www.w3resource.com/python/python-list.php#slice



Question 10

You are an intern for ABC electric cars company. You must create a function that calculates the average velocity of their vehicles on a 1320 foot (1/4 mile) track. The output must be as precise as possible.  
How should you complete the code? To answer, select the appropriate code segments in the answer area. 


Correct answer: To work with this question, an Exam Simulator is required.
Explanation:
References: https://www.w3resource.com/python/python-data-type.php
References: https://www.w3resource.com/python/python-data-type.php









CONNECT US

Facebook

Twitter

PROFEXAM WITH A 20% DISCOUNT

You can buy ProfExam with a 20% discount!



HOW TO OPEN VCEX FILES

Use ProfExam Simulator to open VCEX files