Lesson 8: Programming and App Development

Réussis tes devoirs et examens dès maintenant avec Quizwiz!

What is the difference between a procedure and a function? A. A procedure does something, while a function does something and then returns a value to the main program. B. A function does something, while a procedure does something and then returns a value to the main program. C. A procedure is a container that can grow or shrink in size during program execution as elements are added or removed, while a function cannot be resized. D. A function is a container that can grow or shrink in size during program execution as elements are added or removed, while a procedure cannot be resized.

A. A procedure does something, while a function does something and then returns a value to the main program. The key difference between a procedure and a function is that the latter can return a value to whatever program or process called it. A procedure just "does something" without returning a value to the main program. A function will do something and return a value to the main program, while a procedure just does something. Procedures and functions are not containers. Vectors are containers that can grow or shrink in size as elements are added or removed. Procedures and functions are not containers. Unlike a vector, one of the limitations of the array container type is that it cannot be resized.

What three things define an object? A. Properties, attributes, and methods B. Branches, loops, and operators. C. Data, information, and insights D. Stored value, class, and interface

A. Properties, attributes, and methods An object is defined by three things: Attributes, methods, and properties. Attributes are values and data types that define the object. Methods define what you can do to an object. Properties represent an alternative way of accessing a field publicly. Branches, loops, and operators are programming concepts not objects. Data, information, and insights are used to describe analytics and are not Object-Oriented Programming (OOP) objects. Stored value, class, and interface are considered identifiers. An identifier is used in a program to access a program element, such as a stored value, class, method, or interface.

What shows the structure of code without using the specific syntax of any one language? A. Pseudocode B. Variables C. Functions D. Conditional statements

A. Pseudocode Pseudocode is a code-like language that does not use a specific syntax for a particular programming language. It contains many of the same features (like variables, functions, and conditional statements) but it is generic and can be used as a guide to developing the actual source code. Variables are structures that store data input by users and are included within pseudocode. Functions are collections of code that perform common tasks, like writing to the display or adding two numbers. Functions are included within pseudocode. Conditional statements only execute a part of the code when certain conditions are met. Conditional statements are included within pseudocode.

What is the best way to install a web application on your computer? A. You do not install a web application on your computer. You access it through your browser. B. Go to the vendor's website and have them mail it to you and install it when the disk arrives. C. Download it from the browser and install it on the computer. D. Call in an IT specialist to come install it for you.

A. You do not install a web application on your computer. You access it through your browser. You do not install a web application on your computer. The purpose of a web application is to access it through your browser over the Internet or through a local network. Going to the vendor's website and installing it once it comes in the mail is a way you would buy standard commercial software and install it. Downloading it from the browser and loading it on your computer is just like loading a standard application. Web Application are different from standard applications because they do not need to be installed. Calling in an IT specialist to come install it for you may be embarrassing because web applications are not installed on your computer.

In a program, what does a loop do? A. A loop is a container that can be used as a term to reference multiple values or elements. B. A loop accesses a program element, such as a stored value, class, method, or interface. C. A loop performs one or more instructions until a condition is met. D. Loops grow or shrink in size as elements are added or removed.

C. A loop performs one or more instructions until a condition is met. In computer programming, a loop is a sequence of instructions that is continually repeated until a certain condition is reached. Typically, a certain process is done, such as getting an item of data and changing it, and then some condition is checked such as whether a counter has reached a prescribed number. An identifier is used in a program to access a program element, such as a stored value, class, method, or instance. A loop can manipulate an identifier. A container that can be used as a term to reference multiple values is a simple array. Loops do not grow or shrink in size as elements are added or removed. This is the definition of a vector.

You want to check whether a condition has been met, and if it has, perform one action. Otherwise, you want your program to perform a second action. What sort of programming operation would help achieve this? A. A programming identifier B. A conditional branch C. A simple array D. A continuous loop

B. A conditional branch Branches are instructions to your computer to execute a different sequence of instructions based on a condition. In this scenario, the conditional branch being used is called an IF-THEN-ELSE statement. An identifier is used in a program to access a program element, such as a stored value, class, method, or interface. A program identifier is often used within a conditional branch as part of the logical test. A simple array is an example of a container that can be used as a term to reference multiple values (or elements). An array can also be used within a conditional branch as part of the logical test. A continuous loop executes a sequence of instructions repeatedly until a particular condition is met. A loop differs from a branch because the branch redirects the program flow.

How does a markup language differ from a compiled language? A. A compiled language is not a programming language, rather it is a way of using nested tags within a document to describe its structure and contents. B. A markup language is not a programming language, rather it is a way of using nested tags within a document to describe its structure and contents. C. A markup language is a programming language and is commonly used to retrieve data from a database. D. A compiled language is a programming language and is commonly used to retrieve data from a database.

B. A markup language is not a programming language, rather it is a way of using nested tags within a document to describe its structure and contents. A markup language is not considered a programming language. It uses nested tags within a document to describe its structure and contents. Compiled languages, like C++, use syntax to perform actions which are compiled and linked resulting in an executable file. A compiled language is a programming language. A compiled language does not use nested tags the way a markup language does. A markup language is not used to retrieve data from a database. A query language performs that function. A compiled language does not retrieve data from a database. A query language performs that function.

What is the advantage of a local network hosted application, in terms of data storage? A. If data is stored on the server and not on the local workstation, it will be available to the user if a network device fails. B. If data is stored on the server and not on the local workstation, it is easier to apply access controls and to back it up. C. If data is stored on the server and not on the local workstation, it will be available during power outages. D. If data is stored on a local network storage device and not on specific workstations, different users will not be able to access the information.

B. If data is stored on the server and not on the local workstation, it is easier to apply access controls and to back it up. If data is stored on the server and not on the local workstation, it is easier to apply access controls and to back it up. Having user data consolidated on a server gives administrators the ability to run data backup routines, which are a safeguard in case of hardware failure. Access controls are also easier to implement when files are on the server. Files stored on a local network server will not be accessible by the workstation if a network device fails. A power outage will prevent access to the stored data, unless backup power is provided. When data is stored on a local network storage device, that data can be made accessible to users. Utilizing specific workstations doesn't impact the network storage.

What are constants and variables examples of? A. Simple arrays B. Programming identifiers C. Conditional branches D. Continuous loops

B. Programming identifiers An identifier is used in a program to access a program element, such as a stored value, class, method, or interface. For example, you might assign the identifier FirstName to a stored value that contains a user's first name. In essence, an identifier is a label for something within your program. If your identifier stores data, then it will be either a variable or a constant. A simple array is an example of a container that can be used as a term to reference multiple values (or elements). Branches are instructions to your computer to execute a different sequence of instructions by breaking away from the current program flow based on meeting a condition. A loop is a sequence of instructions that is continually repeated until a certain condition is reached. Typically, a certain process is done, such as getting an item of data and changing it, and then some condition is checked, such as whether a counter has reached a prescribed number.

What type of programming concept allows for a variable size container? A. A procedure B. An array C. A vector D. A function

C. A vector The programming concept that allows for a variable size container is a vector. Vectors can grow or shrink in size as elements are added or removed. In contrast, one of the limitations of the array container type is that it cannot be resized. A procedure enables you to create segments of code that you will reuse. However, you cannot return a value to whatever process called it. A procedure is not a container. A function also enables you to create segments of code that you will reuse. A function is not a container.

What three scripting options are commonly used in Windows 10 to perform administrative tasks? A. PowerCLI, Perl, and Python B. Mocha, LiveScript, and JavaScript C. Batch files, Windows PowerShell scripts, and VBScripts D. AppleScript Editor, Xcode, and Smile

C. Batch files, Windows PowerShell scripts, and VBScripts Batch files, Windows PowerShell scripts, and VB Scripts are the three scripting options commonly used in Windows 10 to perform administrative activities and other tasks. Mocha, LiveScript, and JavaScript are three scripting options commonly used in internet browsers and web servers to perform administrative activities and other tasks. PowerCLI, Perl, and Python are used in the VMWare virtual environment for scripting administrative activities and other tasks. AppleScript Editor, Xcode, and Smile are script languages used for Apple products like, iPhones, iPads, and Macbook Pros for administrative activities and other tasks.

What is an interpreted programming language? A. Interpreted languages represent machine code in human-readable text and are typically specific to a particular hardware architecture. B. Interpreted languages do not need to be compiled and are designed to retrieve specific records from a data set. C. Interpreted languages do not need to be compiled because the code gets converted to machine code at runtime. D. Interpreted languages organize data through structured nested tags and are rendered by a web browser.

C. Interpreted languages do not need to be compiled because the code gets converted to machine code at runtime. Interpreted languages do not need to be compiled. They convert the code to machine code during runtime. Python, Perl, and JavaScript are all popular forms of interpreted programming languages. A language that does not need to be compiled and is designed to retrieve specific records from a data set is called a query language (i.e., SQL). A language that represents machine code in human-readable text that is also specific to a particular hardware architecture is called assembly language. A language that organizes data through structured nested tags and is rendered by a web browser is called Hypertext Markup Language (HTML).


Ensembles d'études connexes

PrepU Ch 36: Management of Patients with Musculoskeletal Disorders

View Set

Basic insurance concept and principles

View Set

PrepU Chapter 21 Developmental Concepts

View Set

Chapter 13: The Respiratory System Test Review

View Set

Chp 13 (Solubility Rules, Ionic Equations, Electrolyte, Colloid, Suspension and Solution Questions)

View Set

Study Guide Lesson 14: The Intellectual Virtues

View Set

Advanced First Aid/ Stretcher Bearer 310

View Set

Nurses Touch: Nursing informatics and technology-Virtual Social Networks

View Set