Scripting and Remote Access Flashcards
Which statement about scripting languages is true?
Scripting languages require a computer
Scripting languages are strongly typed
Scripting languages are interpreted
Scripting languages are interpreted
Scripting languages are interpreted languages that run on top of a runtime environment. Programming languages, not scripting languages, require a compiler. Scripting languages are not strongly typed; programming languages are strongly typed. Scripting languages have bad memory management because of loosely typed variables
What level are scripting languages considered?
High
Mid
Low
High
Scripting languages are considered high-level languages because they do not directly access hardware and use an intermediary called the interpreter. Mid-level languages are Java and C/C++, not scripting languages. There is no such thing as an intermediate-level language. Low-level languages are machine language and assembly language, which are not scripting languages
Which type of variable will allow decimal math?
Integer
Floating point
String
Floating point
Floating-point variables allow for precision math, also known as decimal math. Boolean variables allow for true or false values. Integer variables allow for whole numbers values. String variables allow for text values
Which environment variable is not inherited?
System variable
User variable
Program variable
Program variable
A program variable is the least significant and not inherited. A system variable is defined for the entire system and is the most significant because it is inherited by all users and programs. A user variable is significant as well, since all applications will inherit the variable. A string variable is not inherited, but it is not an environment variable
Which statement will load a PowerShell variable xvar with a value of 2?
xvar = 2
$xvar = 2
xvar = 2;
$xvar = 2
The statement $xvar = 2 is a PowerShell statement that will load the variable xvar with a value of 2. The statement xvar = 2 is Bash syntax. The statement xvar = 2; is JavaScript syntax. The statement set /a xvar=2 is a Windows batch script syntax
Which type of loop has a defined beginning and end, and steps from beginning to end?
while loop
if statement
for loop
for loop
A for loop has a defined beginning and end, and steps from the beginning to the end. A do while loop is a type of while loop and has only a defined end. A while loop has only a defined end. An if statement is branch logic, not a loop
Which extension is used with the Windows batch scripting language?
.vbs
.js
.bat
.bat
The .bat extension is used with the Windows batch scripting language. The .vbs extension is used with VBScript language. The .js extension is used with the JavaScript scripting language. The .py extension is used with the Python scripting language
Which scripting language allows for the use of the Component Object Model (COM)?
PowerShell
VBScript
JavaScript
VBScript
The VBScript language allows for the use of the Component Object Model (COM). The PowerShell scripting language allows for the use of the .NET Framework. Windows batch scripts use existing applications. JavaScript is primarily web browser–based and does not allow for the use of external objects
Which extension is used with the Python scripting language?
.vbs
.js
.py
.py
The .py extension is used with the Python scripting language. The .vbs extension is used with the VBScript language. The .js extension is used with the JavaScript scripting language. The .bat extension is used with the Windows batch scripting language
Which scripting language is used with Microsoft Azure and Office 365?
PowerShell
VBScript
Windows batch script
PowerShell
The PowerShell scripting language allows for the use of the .NET Framework and is commonly used with Microsoft Azure and Office 365. The VBScript language allows for the use of the Component Object Model (COM) and is not used for cloud services. Windows batch script uses existing applications and is not used for cloud services. JavaScript is primarily web browser–based, does not allow for the use of external objects, and is not used for cloud services
Which scripting language is used within pages to allow for interactive content?
PowerShell
Bash
JavaScript
JavaScript
JavaScript is primarily web browser–based and allows for interactive content. The PowerShell scripting language is used to manage the operating system. The Bash scripting language is primarily used with Linux and UNIX systems. Windows batch scripts use existing applications and are used to manage the operating system
Which extension is used with the Bash scripting language?
.vbs
.sh
.bat
.sh
The .sh extension is used with the Bash scripting language. The .vbs extension is used with the VBScript language. The .bat extension is used with the Windows batch scripting language. The .py extension is used with the Python scripting language
What must be done before a Bash script can be executed?
chown permissions must be set
The execute attribute must be set
chmod permissions must be set
chmod permissions must be set
Before a script can be executed, you must use the chmod command to grant execute permissions. The chown command changes ownership. There is no such thing as an execute attribute. Adding .sh to the end of the script doesn’t serve any purpose
Which statement will load a JavaScript variable mvar with a value of 8?
$mvar = 8
mvar = 8
mvar = 8;
mvar = 8;
The statement mvar = 8; is JavaScript syntax to load a variable of mvar with a value of 8. The statement $mvar = 8 is PowerShell syntax. The statement mvar = 8 is Bash syntax. The statement set /a mvar=8 is Windows batch script syntax
Which scripting language has its own preinstalled Integrated Scripting Environment (ISE)?
Bash
Python
PowerShell
PowerShell
PowerShell is the only scripting language that has a preinstalled Integrated Scripting Environment (ISE), called the PowerShell ISE. The VBScript language requires the installation of Microsoft Visual Studio Code. The Bash scripting language requires a text editor or other package to be installed. The Python scripting language requires a third-party integrated development environment (IDE), also known as an ISE