Answer:
What's wrong?
The line_str variable needs to be re-initialized at the end of each printing
The correction
Include the following line immediately after the print statement
line_str = ""
Explanation:
Required
Correct the code
The conditions are correct. However, the string variable line_str needs to be set to an empty string at the end of every of the iteration loop.
This will allow the code to generate a new string.
So, the complete function is:
def swapping_stars():
line_str = ""
for line in range(0, 6):
for char in range(0,6):
if line % 2 == char%2:
line_str += "*"
else:
line_str += "-"
print(line_str)
line_str = ""
Unlike the collapse of Enron and WorldCom, TJX did not break any laws. It was simply not compliant with stated payment card processing guidelines.
a) true
b) false
The statement "Unlike the collapse of Enron and WorldCom, TJX did not break any laws. It was simply not compliant with stated payment card processing guidelines" is definitely true.
What was the cause of the TJX data breach?The major cause of the TJX data breach was thought to be the hack that wasn't discovered until 2007, hackers had first gained access to the TJX network in 2005 through a WiFi connection at a retail store.
These situations were eventually able to install a sniffer program that could recognize and capture sensitive cardholder data as it was transmitted over the company's networks. They should be required to change the encryption methodology of the data they are using to save the personal identification information of their customers.
Therefore, the statement "Unlike the collapse of Enron and WorldCom, TJX did not break any laws. It was simply not compliant with stated payment card processing guidelines" is definitely true.
To learn more about, TJX data, refer to the link:
https://brainly.com/question/22516325
#SPJ2
Create a function void process(char ch, int x, int y)- to accept an arithmetic operator (+,-./, in argum
ch and two integers in arguments x and y. Now on the basis of the operator stored in ch perform the operator
in x and y and print the final result. Also, write a main function to input the two integers and an arithmetit
operator, and by invoking function process() print the output.
Example: Input:
First Integer
Second Integer
: 6
Value of ch
Output: The result of 5 and 7 on * = 24
write in java
Answer:
The program is as follows:
import java.util.*;
public class Main{
public static void process(char ch, int x, int y){
if(ch == '+'){
System.out.print(x+y); }
else if(ch == '-'){
System.out.print(x-y); }
else if(ch == '*'){
System.out.print(x*y); }
else if(ch == '/'){
if(y!=0){
double num = x;
System.out.print(num/y); }
else{
System.out.print("Cannot divide by 0"); } }
else{
System.out.print("Invalid operator"); }
}
public static void main(String[] args) {
Scanner input = new Scanner(System.in);
int x, y;
char ch;
System.out.print("Enter two integers: ");
x = input.nextInt(); y = input.nextInt();
System.out.print("Enter operator: ");
ch = input.next().charAt(0);
process(ch,x, y);
}
}
Explanation:
The function begins here
public static void process(char ch, int x, int y){
If the character is +, this prints the sum of both integers
if(ch == '+'){
System.out.print(x+y); }
If the character is -, this prints the difference of both integers
else if(ch == '-'){
System.out.print(x-y); }
If the character is *, this prints the product of both integers
else if(ch == '*'){
System.out.print(x*y); }
If the character is /, this prints the division of both integers.
else if(ch == '/'){
if(y!=0){
double num = x;
System.out.print(num/y); }
else{
This is executed if the denominator is 0
System.out.print("Cannot divide by 0"); } }
Invalid operator is printed for every other character
else{
System.out.print("Invalid operator"); }
}
The main begins here
public static void main(String[] args) {
Scanner input = new Scanner(System.in);
This declares both integers
int x, y;
This declares the operator
char ch;
Get input for both integers
System.out.print("Enter two integers: ");
x = input.nextInt(); y = input.nextInt();
Get input for the operator
System.out.print("Enter operator: ");
ch = input.next().charAt(0);
Call the function
process(ch,x, y);
}
}
what is function of java
Explanation:
Java is an object-orinted programming language used for software develpment.
The _____ of the Open Systems Interconnection (OSI) modelspecifies the electrical connections between computers and the transmission medium and is primarily concerned with transmitting binary data, or bits, over a communication network.
Answer:
"Physical layer" is the correct answer.
Explanation:
It dealt mostly with bit-level transfer across various equipment as well as it provides industrial automation connections to meet quality standards to something like digital downloads.The purpose of this layer would be to consolidate essential networking system compatibility so that information is being sent successfully.Thus, the above is the correct answer.
which function would ask excel to average the values contained in cells C5,C6,C7, and C8
Answer:
=AVERAGE(C5:C8)
Explanation:
The function calculates the average of the values in the cell range C5:C8 - C5, C6, C7, C8.
Aaron opens a bicycle store. Which of the
following gives the best example of how Aaron
uses the scarce resource of labor?
Answer: Aaron hired an employee to do bicycle repairs
Explanation:
Labor refers to the physical and mental effort put into production by human beings.
Since Aaron opens a bicycle store, he can hire an employee to do bicycle repairs. Therefore, in this case, labor will be put into productive use for the company.
What is the meaning of negative impact in technology
Answer:
the use of criminal thought by the name of education
How do you find the average length of words in a sentence with Python?
Answer:
split() wordCount = len(words) # start with zero characters ch = 0 for word in words: # add up characters ch += len(word) avg = ch / wordCount if avg == 1: print "In the sentence ", s , ", the average word length is", avg, "letter." else: print "In the sentence ", s , ", the average word length is", avg, "letters.
True/False: The American Standard Code for Information (ASCII) is a code that allows people to read information on a computer.
True
False
2.
The program is the set of instructions a computer obeys.
True
False
3.
A flash drive, dvd, and hard drive are all examples of:
storage
processing
output
input
4.
An example of an Input device is:
speaker
monitor
keyboard
CPU
5.
How many bits are in a byte?
16
8
24
32
6.
The part of the computer that processes all the inputs and outputs is the:
Monitor
Mouse
CPU
Tower
7.
Match the word to its definition:
1.
Smart phone
2.
Program
3.
Super computer
4.
Desktop
5.
Tablet
6.
Computer
7.
Mainframes
8.
Notebook
a.
An individual’s personal computer that resides on a desk or table
b.
A small portable computer, such as a netbook
c.
A device that includes, text, and data capabilities
d.
A large and powerful scientific computer that can process large amounts of data quickly
e.
The coded instructions that tell a computer what to do; also to write the code for a program
f.
A computer that combines the features of a graphic tablet with the functions of a personal computer; sometimes called a tablet PC
g.
Is a machine that changes information from one form into another by performing four basic actions
h.
A type of computer used by many people at the same time to allow access to the same secure data
8.
The four functions of a computer are (check all that apply):
processing
input
output
storage
9.
An example of an Output device is:
barcode reader
keyboard
monitor
mouse
10.
Which of the following are part of a computer (check all that apply):
mouse
tower
keyboard
11.
A storage device is both input and output together.
True
False
Answer:
Find answers below.
Explanation:
1. True: The American Standard Code for Information Interchange (ASCII) is a code that allows people to read information on a computer. It is used for representing numbers through 128 English characters.
2. True: a program is the set of instructions a computer obeys to perform a specific task.
3. A flash drive, dvd, and hard drive are all examples of: storage device. They are used for storing data, informations and instructions.
4. An example of an Input device is: a keyboard. An input device can be defined as any device that is typically used for sending data to a computer system.
5. There are 8 bits are in a byte; 1 byte = 8 bits.
In Computer science, a bit is a short word for the term binary digit and is primarily the basic (smallest) unit measurement of data or information. A bit is a logical state which represents a single binary value of either one (1) or zero (0).
6. The part of the computer that processes all the inputs and outputs is the: central processing unit (CPU).
Match the word to its definition:
a. Desktop: an individual’s personal computer that resides on a desk or table.
b. Notebook: a small portable computer, such as a netbook.
c. Smart phone: a device that includes, text, and data capabilities.
d. Supercomputer: a large and powerful scientific computer that can process large amounts of data quickly.
e. Program: the coded instructions that tell a computer what to do; also to write the code for a program.
f. Tablet: computer that combines the features of a graphic tablet with the functions of a personal computer; sometimes called a tablet PC.
g. Computer: is a machine that changes information from one form into another by performing four basic actions.
h. Mainframe: a type of computer used by many people at the same time to allow access to the same secure data.
8. The four functions of a computer are:
processing, input, output and storage.
9. An example of an Output device is: monitor. An output device can be defined as a hardware device that typically receives processed data from the central processing unit (CPU) and converts these data into information that can be used by the end user of a computer system.
10. The parts of a computer:
keyboard and mouse.
11. False: storage device is both input and output together. A storage device is a hardware device used for holding data (informations) either permanently or temporarily.
Caleb Co. owns a machine that had cost $42,400 with accumulated depreciation of $18,400. Caleb exchanges the machine for a newer model that has a market value of $52,000. 1. Record the exchange assuming Caleb paid $30,000 cash and the exchange has commercial substance. 2. Record the exchange assuming Caleb paid $22,000 cash and the exchange has commercial substance.
Answer: See explanation
Explanation:
1. Record the exchange assuming Caleb paid $30,000 cash and the exchange has commercial substance.
Dr Machine (new) $52000
Dr Loss on exchange of asset $2000
Dr Accumulated Depreciation $18400
Cr Equipment (Old) $42400
Cr Cash $30000
Nite that loss was calculated as:
= Market value of new machine - (Book value if old machine - Depreciation) - Cash paid
= $52000 - ($42400 - $18400) - $30000
= $52000 - $24000 - $30000
= -$2000
2. Record the exchange assuming Caleb paid $22,000 cash and the exchange has commercial substance
Dr Machine (new) $46000
Dr Accumulated Depreciation $18400
Cr Equipment (Old) $42400
Cr Cash $22000
Note that the value of the new machine was calculated as:
= Original cost + Cash paid - Accumulated Depreciation
= $42000 + $22000 - $18400
= $46000
What does the abbreviation BBC stands for?
Answer:
British Broadcasting Corporation Microcomputer System
Explanation:
The British Broadcasting Corporation Microcomputer System, or BBC Micro, is a series of microcomputers and associated peripherals designed and built by the Acorn Computer company in the 1980s for the BBC Computer Literacy Project.
Answer:
British Broadcasting Corporation
Explanation:
This is a UK company which provides television and radio news in over 40 languages. This is the computer related meaning, there are other meanings to the abbreviation but they seem irrelevant in this case.
Hope this information was of any help to you. (:
Write an application that inputs a five digit integer (The number must be entered only as ONE input) and separates the number into its individual digits using MOD, and prints the digits separated from one another. Your code will do INPUT VALIDATION and warn the user to enter the correct number of digits and let the user run your code as many times as they want (LOOP). Submit two different versions: Using the Scanner class (file name: ScanP2)
Answer:
The program in Java is as follows:
import java.util.*;
public class Main{
public static void main(String[] args) {
int n, num;
Scanner input = new Scanner(System.in);
System.out.print("Number of inputs: ");
n = input.nextInt();
LinkedList<Integer> myList = new LinkedList<Integer>();
for(int i = 0; i<n;i++){
System.out.print("Input Integer: ");
num = input.nextInt();
while (num > 0) {
myList.push( num % 10 );
num/=10;
}
while (!myList.isEmpty()) {
System.out.print(myList.pop()+" ");
}
System.out.println();
myList.clear();
}
}
}
Explanation:
This declares the number of inputs (n) and each input (num) as integer
int n, num;
Scanner input = new Scanner(System.in);
Prompt for number of inputs
System.out.print("Number of inputs: "); n = input.nextInt();
The program uses linkedlist to store individual digits. This declares the linkedlist
LinkedList<Integer> myList = new LinkedList<Integer>();
This iterates through n
for(int i = 0; i<n;i++){
Prompt for input
System.out.print("Input Integer: ");
This gets input for each iteration
num = input.nextInt();
This while loop is repeated until the digits are completely split
while (num > 0) {
This adds each digit to the linked list
myList.push( num % 10 );
This gets the other digits
num/=10;
}
The inner while loop ends here
This iterates through the linked list
while (!myList.isEmpty()) {
This pops out every element of thelist
System.out.print(myList.pop()+" ");
}
Print a new line
System.out.println();
This clears the stack
myList.clear();
}
How could you use your technology skill and Microsoft Excel to organize, analyze, and compare data to decide if a specific insurance is a good value for the example you gave
Answer:
The summary of the given question would be summarized throughout the below segment.
Explanation:
"Insurance firms voluntarily assume our charge probability," implies assurance undertakings will compensate including all our devastations throughout respect of products for something we have health coverage and that the vulnerability for both would be equivalent.If somehow the client receives significant losses, the firm must compensate that kind of money as well as, if there are no failures, it can invest earnings or rather an investment.TP1. लेखा अभिलेखको अर्थ उल्लेख गर्नुहोस् । (State the mea
TP2. लेखाविधिलाई परिभाषित गर्नुहोस् । (Define accounting.
TP 3. लेखाविधिको कुनै तीन महत्वपूर्ण उद्देश्यहरू लेख्नुहोस्
accounting.)
Explanation:
TP1. लेखा अभिलेख भनेको ज्ञानको त्यस्तो शाखा हो, जुन व्यवसायको आर्थिक कारोबारहरूलाई नियमित, सु-व्यवस्थित र क्रमबद तरिकाले विभिन्न पुस्तिकाहरूमा अभिलेख गर्ने कार्यसँग सम्बन्धित छ।
What layer of the OSI model describes how data between applications is synced and recovered if messages don't arrive intact at the receiving application?
A) Application Layer.
B) Presentation Layer.
C) Session Layer.
D) Transport Layer.
Answer:
C) Session Layer.
Explanation:
OSI model stands for Open Systems Interconnection. The seven layers of OSI model architecture starts from the Hardware Layers (Layers in Hardware Systems) to Software Layers (Layers in Software Systems) and includes the following;
1. Physical Layer
2. Data link Layer
3. Network Layer
4. Transport Layer
5. Session Layer
6. Presentation Layer
7. Application Layer
Basically, each layer has its unique functionality which is responsible for the proper functioning of the communication services.
Session layer is the layer of an Open Systems Interconnection (OSI) model which describes how data between applications is synced and recovered if messages don't arrive intact at the receiving application.
Write an expression that executes the loop while the user enters a number greater than or equal to 0. Note: These activities may test code with different test values. This activity will perform three tests, with user input of 9, 5, 2, -1, then with user input of 0, -17, then with user input of 0 1 0 -1. See "How to Use zyBooks". Also note: If the submitted code has an infinite loop, the system will stop running the code after a few seconds, and report "Test aborted."
Answer:
while ( num >= 0) { ... }
Explanation:
Required
Express to execute a while loop with the given condition.
The condition in the question is that: the user input must be greater than or equal to 0.
The statement for this is:
[tex]while[/tex] ( [tex]num[/tex] [tex]>=[/tex] [tex]0[/tex]) { [tex]...[/tex] }
Where num is the input variable
seven and two eighths minus five and one eighth equals?
Answer: 2.125
Explanation
An operating system that allows a single user to work on two or more programs at the same time is what type of OS?
Answer:
Explanation:
The correct answer is none of these
An operating system that allows a single user to perform only one task at a time is called a Single-User Single-Tasking Operating System. Functions like printing a document, downloading images, etc., can be performed only one at a time. Examples include MS-DOS, Palm OS, etc.
Advantage: This operating system occupies less space in memory.
Disadvantage: It can perform only a single task at a time.
There are four types of operating systems −
Real-time operating system
Single-User/Single-Tasking operating system
Single-User/Multitasking operating system
Multi-User/Multitasking operating system
Real-time operating system is designed to run real-time applications. It can be both single- and multi-tasking. Examples include Abbasi, AMX RTOS, etc.
An operating system that allows a single user to perform more than one task at a time is called Single-User Multitasking Operating System. Examples include Microsoft Windows and Macintosh OS.
It is an operating system that permits several users to utilize the programs that are concurrently running on a single network server. The single network server is termed as "Terminal server". "Terminal client" is a software that supports user sessions. Examples include UNIX, MVS, etc.
By comparing the time out mechanism used in TCP to that used in a data link layer protocol, outline why it is necessary for the TCP timeout mechanism to implement an adaptive timeout duration
Answer:
When there are network flows within the wireless link that experience prolonged poor transmission it can impact on the network, leading to the stalling of the source while waiting for the arrival of ACKS, due to the filling of the TCP source congestion window. More time is lost as the source waits for a timeout to be caused by the expiration of the RTO timer which results in lower efficiency and network throughput by the TCP that requires an adaptive timeout duration to be implemented
Explanation:
Which of the following statement is False? 1 point Context free language is the subset of context sensitive language Regular language is the subset of context sensitive language Recursively enumerable language is the super set of regular language Context sensitive language is a subset of context free language
Answer:
Context-sensitive language is a subset of context-free language
Explanation:
Considering the available options, the statement that is considered wrong is "Context-sensitive language is a subset of context-free language."
This is because generally every regular language can be produced through the means of context-free grammar, while context-free language can be produced through the means of context-sensitive grammar, and at the same time, context-sensitive grammars are produced through the means of Recursively innumerable.
Hence, the correct answer in this correct answer to the question is the last option *Context-sensitive language is a subset of context-free langage
Of the following is a principle of total quality management?
A. Continuous defect elimination
B. Continuous process improvement
C. Continuous value enhancement
D. Continuous productivity improvement
Write a program that reads the balance and annual percentage interest rate and displays the interest for the next month. Python not JAVA
Answer:
Explanation:
The following code is written in Python. It asks the user to enter the current balance and the annual interest rate. It then calculates the monthly interest rate and uses that to detect the interest that will be earned for the next month. Finally, printing that to the screen. A test output can be seen in the attached picture below.
balance = int(input("Enter current Balance: "))
interest = int(input("Enter current annual interest %: "))
interest = (interest / 12) / 100
next_month_interest = balance * interest
print('$ ' + str(next_month_interest))
As a CISO, you are responsible for developing an information security program based on using a supporting framework. Discuss what you see as some major components of an information security program.
Answer:
The CISO (Chief Information Security Officer) of an organization should understand the following components of an information security program:
1) Every organization needs a well-documented information security policy that will govern the activities of all persons involved with Information Technology.
2) The organization's assets must be classified and controlled with the best industry practices, procedures, and processes put in place to achieve the organization's IT objectives.
3) There should be proper security screening of all persons in the organization, all hardware infrastructure, and software programs for the organization and those brought in by staff.
4) Access to IT infrastructure must be controlled to ensure compliance with laid-down policies.
Explanation:
As the Chief Information Security Officer responsible for the information and data security of my organization, I will work to ensure that awareness is created of current and developing security threats at all times. I will develop, procure, and install security architecture, including IT and network infrastructure with the best security features. There will good management of persons' identity and controlled access to IT hardware. Programs will be implemented to mitigate IT-related risks with due-diligence investigations, and smooth governance policies.
Frames control what displays on the Stage, while keyframes help to set up
Answer: A keyframe is a location on a timeline which marks the beginning or end of a transition. So for example, you have a movie and it transitions to another scene, keyframes tell it when and where to start the transition then when and where to stop the transition.
The imperative programming paradigm is popular and is a part of object-oriented computing paradigm, because it: __________.
A. is based on computer organization and thus is efficient to execute on hardware.
B. matches the culture of doing things by following the step-wise instructions.
C. enforces the modularity and supports the development of large programs.
D. supports class inheritance and code reuse.
Answer:
B. Matches the culture of doing things by following the step-wise instructions.
Explanation:
Imperative programming paradigm follows a sequence of instructions and steps. The order of execution of the statement is necessary because their is sequence of statements. Operation is system oriented.
In imperative programming, the source code is a series of commands, this commands tell the computer what to do, when to do it and the order it will be done so as to achieve the best result. The code of imperative programming paradigm is quite easy to understand.
Any help , and thank you all
Answer:
There are 28 chocolate-covered peanuts in 1 ounce (oz). Jay bought a 62 oz. jar of chocolate-covered peanuts.
Problem:
audio
How many chocolate-covered peanuts were there in the jar that Jay bought?
Enter your answer in the box.
Explanation:
Write a program that estimates how many years, months, weeks, days, and hours have gone by since Jan 1 1970 by calculations with the number of seconds that have passed.
Answer:
Explanation:
The following code is written in Java. It uses the LocalDate import to get the number of seconds since the epoch (Jan 1, 1970) and then uses the ChronoUnit import class to transform those seconds into years, months, weeks days, and hours. Finally, printing out each value separately to the console. The output of the code can be seen in the attached picture below.
import java.time.LocalDate;
import java.time.temporal.ChronoUnit;
class Brainly {
public static void main(String[] args) {
LocalDate now = LocalDate.now();
LocalDate epoch = LocalDate.ofEpochDay(0);
System.out.println("Time since Jan 1 1970");
System.out.println("Years: " + ChronoUnit.YEARS.between(epoch, now));
System.out.println("Months: " + ChronoUnit.MONTHS.between(epoch, now));
System.out.println("Weeks: " + ChronoUnit.WEEKS.between(epoch, now));
System.out.println("Days: " + ChronoUnit.DAYS.between(epoch, now));
System.out.println("Hours: " + (ChronoUnit.DAYS.between(epoch, now) * 24));
}
}
In this module you learned about advanced modularization techniques. You learned about the advantages of modularization and how proper modularization techniques can increase code organization and reuse.
Create the PYTHON program allowing the user to enter a value for one edge of a cube(A box-shaped solid object that has six identical square faces).
Prompt the user for the value. The value should be passed to the 1st and 3rd functions as arguments only.
There should be a function created for each calculation
One function should calculate the surface area of one side of the cube. The value calculated is returned to the calling statement and printed.
One function should calculate the surface area of the whole cube(You will pass the value returned from the previous function to this function) and the calculated value results printed.
One function should calculate the volume of the cube and print the results.
Make a working version of this program in PYTHON.
Answer:
Following are the code to the given question:
def getSAOneSide(edge):#defining a method that getSAOneSide that takes edge patameter
return edge * edge#use return to calculate the edge value
def getSA(SA_one_side):#defining a method that getSA that takes SA_one_side patameter
return 6 * SA_one_side#use return to calculate the SA_one_side value
def volume(edge):#defining a method that volume that takes edge patameter
return edge * edge * edge#use return to calculate edge value
edge = int(input("Enter the length of edge of the cube:\n"))#defining edge variable that input value
SA_one_side = getSAOneSide(edge)#defining SA_one_side that holds getSAOneSide method value
print("Surface area of one side of the cube:", SA_one_side)
surfaceArea = getSA(SA_one_side)#defining a surfaceArea that holds getSA method value
print("Surface area of the cube:", surfaceArea)#print surfaceArea value
vol = volume(edge)#defining vol variable that holds Volume method value
print("Volume of the cube:", vol)#print vol Value
Output:
Please find the attached file.
Explanation:
In the code three method "getSAOneSide, getSA, and volume" method is declared that takes a variable in its parameters and use a return keyword that calculates and return its value.
In the next step,edge variable is declared that holds value from the user and defines three variable that holds method value and print its value with the message.
1. The smallest unit in a digital system is a
Answer:
a bit
Explanation:
<3
Which of the following statements regarding the SAP Hana product implemented by Under Armour is NOT true?
A. All of the statements are true.
B. The program allows legacy silos to remain intact.
C. The program can run across platforms and devices.
D. The program provides real-time results.
Answer:A
Explanation:i need points