Trace the following pseudocode. List the values of COUNTER and ANSWER throughout and then show the final values.

a. Set COUNTER to 0.
b. Set ANSWER to 100.
c. Divide ANSWER by 2 and set ANSWER to the new result
d. If ANSWER is even, go back to step 3 and add 1 to COUNTER. If ANSWER is odd, go to the next line.
e. Repeat lines 6 and 7 until COUNTER is greater than 3
f. Increase ANSWER by the value of COUNTER.
g. Increase COUNTER by 1.
h. While COUNTER is greater than or equal to 2 do lines 9 and 10.
i. Decrease ANSWER by 5
j. Decrease COUNTER by 1
k. Display ANSWER and COUNTER

Answers

Answer 1

Answer:

ANSWER = 16

COUNTER = 1

Explanation:

a. COUNTER = 0

b. ANSWER = 100

c. ANSWER = 100/2 = 50

d. ANSWER (50) is even, so it goes back to (c)

ANSWER = 50/2 = 25

and

COUNTER = COUNTER + 1 = 0 + 1 =1

ANSWER is now odd (25), so it moves to (e)

e. f and g will be executed as follows.

f. ANSWER = ANSWER + COUNTER = 25 + 1 = 26

g. COUNTER = COUNTER+1 = 1 + 1 = 2.

COUNTER is not greater than 3, so f & g will be executed again

f. ANSWER = 26 + 2 = 28

g. COUNTER = 2 + 1 = 3.

And again

f. ANSWER = 28 + 3 = 31

g. COUNTER = 3 + 1 = 4

Now, execution will proceed to h

h. i and j will be executed as follows

i. ANSWER = ANSWER - 5 = 31 - 5 = 26

j. COUNTER = COUNTER - 1 = 4 - 1 = 3

COUNTER ≥ 2, so it'll be executed again

i. ANSWER = 26 - 5 = 21

j. COUNTER = 3 - 1 = 2

And again...

i. ANSWER = 21 - 5 = 16

j. COUNTER = 2 - 1 = 1

Now, the condition is no longer valid.

So, execution proceed to k

k. The displayed values of ANSWER and COUNTER is 16 and 1, respectively.


Related Questions

Write the statements needed so that the variable secondWord is associated with the second word of the value of sentence . So, if the value of sentence were "Broccoli is delicious." your code would associate secondWord with the value "is" .

Answers

Answer:

Explanation:

String str = "Broccoli is delicious.";

String[] Secondstr = str.split(" ");

System.out.println("second word is " + Secondstr[1]);

Write a program that calculates the occupancy rate for ahotel. The program should start by asking the user how many floorsthe hotel has. A loop should then iterate once for each floor. Ineach iteration, , the loop should ask the user for the number ofrooms on the floor and how many of them are occupied. After all theiterations, the program should display how many rooms the hotelhas, how many of them are occupied, how many are unoccupied, andthe percentage of rooms that are occupied. The percentage may becalculated by dividing the number of rooms occupied by the numberof rooms.
Requirements:
Do not accept a value less than one for the number offloors
Do not accept a value less than 10 for the number ofrooms on the floor
In this hotel, the third floor is used for restaurants. Theloop in this program should skip the entire third iteration.
Use for loop and while loop in the program
Sample ouput
How many floors does the hotel have?
How many rooms are on floor 1?
How many of those rooms are occupied?
How many rooms are on floor 2?
How many of those rooms are occupied?
How many rooms are on floor 4?
How many of those rooms are occupied?
How many rooms are on floor 5?
How many of those rooms are occupied?
How many rooms are on floor 6?
How many of those rooms are occupied?
The hotel has a total of 65 rooms.
53 are occupied.
12 are unoccupied.
The occupancy rate is 81.5%

Answers

Answer:

Here is the C++ program:

#include <iostream>  //to use input output functions

using namespace std;   //to identify objects like cin cout

int main(){  //start of main function

       int MinFloors = 1;  //minimum number of floors

       int MinRooms  = 10; //minimum number of rooms

       int NoOfFloors;  //stores number of floors

       int NoOfRooms;  //stores number of rooms

       int OccupiedRooms;  //stores number of rooms occupied

       double TotalRooms=0, TotalOccupied=0;   //stores computed total number of rooms and total number of occupied rooms

       cout<<"How many floors does the hotel have? ";  //prompts user to enter number of floors

       do{  //iterates until the user enters valid number of floors

           cout<<"(cannot be less than "<<MinFloors<<"): ";  //error message

           cin >>NoOfFloors;  //reads number of floors from user

       }while(NoOfFloors<MinFloors);  //repeats as long as number of floors is less than minimum number of floors

       for(int floor=1; floor <= NoOfFloors; floor++){    //iterates through the floors to skip third iteration

           if(floor == 3){   //if floor is third floor

               continue;             }  

           cout<<"How many rooms are on floor " <<floor;  //prompts user to enter number of floors

           do{  //start of do while loop

               cout<<"(cannot be less than "<<MinRooms<<"): ";  //error message

               cin >>NoOfRooms;  //reads number of rooms from user

           }while(NoOfRooms<MinRooms);    //iterates as long as number of rooms are less than valid minimum number of rooms

           TotalRooms += NoOfRooms;   //adds number of rooms to the count of total number of rooms

           cout<<"How many of those rooms are occupied?";  //prompts user to enter number of rooms occupied

           do{  //start of do while loop

         cout<<"(cannot be less than 0 or greater than "<<NoOfRooms<<"): ";  //generates error message

         cin >>OccupiedRooms;  //reads number of rooms occupied by user

           }while(OccupiedRooms<0 || OccupiedRooms>NoOfRooms);   //iterates as long as the number of occupied rooms are less than 0 or greater than number of rooms

           TotalOccupied += OccupiedRooms;    }    //adds number of rooms occupied to the count of total number of occupied rooms    

       cout<<"\nThe hotel has a total of "<<TotalRooms<<" rooms"<<endl;  //displays the total number of rooms in the hotel

       cout<<TotalOccupied<<" are occupied."<<endl;  //displays the total number of occupied rooms

       cout<<(TotalRooms-TotalOccupied)<<" are unoccupied."<<endl;  //displays the total number of unoccupied rooms

cout<<"The occupancy rate is: "<<100*(TotalOccupied/TotalRooms)<<"%"<<endl;     }  //computes and displays the occupancy rate

   

Explanation:

The program first prompts the user to enter number of floors in the hotel. Lets say user enters 6. This is stored in NoOfFloors So

NoOfFloors = 6

So the loop runs for 6 times

Next it asks user to enter the number of rooms in the floor 1. Lets say user enters 12 so this is stored in NoOfRooms so

NoOfRooms = 12

TotalRooms += NoOfRooms;

this statement keeps adding number of rooms to TotalRooms so

TotalRooms = 12

Next program asks user about the number of occupied rooms. Lets say user enters 10 so this is stored in OccupiedRooms so

OccupiedRooms = 10

this statement keeps adding number of rooms to TotalOccupied so

 TotalOccupied += OccupiedRooms;

TotalOccupied = 10

At next iteration program asks user again to enter number of rooms in floor 2. Suppose user enters 14 so

NoOfRooms = 12

TotalRooms += NoOfRooms;

TotalRooms = 12+14

TotalRooms = 26

Program asks again to enter number of occupied rooms so it becomes:

OccupiedRooms = 8

this statement keeps adding number of rooms to TotalOccupied so

 TotalOccupied += OccupiedRooms;

TotalOccupied = 10+8

TotalOccupied = 18

Next is skips floor 3 and iteration 3. and asks user to enter number of rooms in floor 4. Suppose user enters 14

Number of rooms become:

TotalRooms = 12+14+14

TotalRooms = 40

and suppose user enters 14 as occupied rooms so total occupied become:

TotalOccupied = 10+8 + 14

TotalOccupied = 32

For floor 5: Suppose user enters 13

TotalRooms = 12+14+14+13

TotalRooms = 53

For floor 5: Suppose user enters 10

TotalOccupied = 10+8 + 14+10

TotalOccupied = 42

For floor 6: Suppose user enters 12

TotalRooms = 12+14+14+13+12

TotalRooms = 65

For floor 6: Suppose user enters 11

TotalOccupied = 10+8 + 14+10+11

TotalOccupied = 53

Now the loop breaks

Hence

TotalRooms = 65

TotalOccupied  = 53

total unoccupied = TotalRooms-TotalOccupied = 65-53 = 12

The occupancy rate is: 100*(TotalOccupied/TotalRooms) = 100*(53/65) = 81.5385

The output of the program is attached in a screenshot.

Which options are available in the Conditional Formatting dialog box? Check all that apply.

play a specified sound
create a calendar event
flag message for follow up
stop processing more rules
permanently delete a message
move a message to a specified folder

Answers

Answer:

Except the second one, all are correct.

Explanation:

On edg

Need answer quick
In windows, the desktop is simply a folder that resides in your main user folder.
true or false?​

Answers

Answer:

true

Explanation:

The smallest unit of storage is​

Answers

Answer:

Hey mate......

Explanation:

The smallest unit of storage is Bytes......

hope it helps you,

mark me as the brainliest,

follow me..........

Select the correct navigational path to mark all teachers who have achieved “excellent” on their evaluations a red background. Select the rows or columns you wish to format. Click the (Home, Page layout, data, view) tab on the ribbon and look in the (Clipboard, alignment, number, conditional formatting) gallery. Select (New rule, manage rule, clear rule) . Select ( format only top or bottom, format all cells, use a formula) and fill in the formula for the IF statement and formatting. Click OK.

Answers

Answer:

View, Cond. Form., New rule, Format

Explanation:

:p Don't ask.

Answer:

Click the home tab

conditional formatting

select new rule

select "use a formula"

Explanation:

correct on edge 2020

Look at the following Python code:

word1 = "Umpire"
word2 = word1[0:3]

Which characters will be sliced from word1 and assigned to word2?

Ump
Umpi
mpi
pire

Answers

Ump will be assigned to word2

word1[0:3] gets all of the letters from index 0 to index 3 exclusive (that means index 3 is not included)

(01.05 LC)

When a user responds to a prompt, their response is known as __________.

input
output
text
value

Answers

The answer is input! because the input is what the user enters, the output is what comes out from that, and the text and value aren’t related to the user
Their answer is known as an input, because they are saying what they know/think. Sorry if this didnt help have a nice day though^^

Warm up: Variables, input, and casting
(1) Prompt the user to input an integer, a double, a character, and a string, storing each into separate variables. Then, output those four values on a single line separated by a space.
Note: This zyLab outputs a newline after each user-input prompt. For convenience in the examples below, the user's input value is shown on the next line, but such values don't actually appear as output when the program runs.
Enter integer: 99 Enter double: 3.77 Enter character: Z Enter string: Howdy 99 3.770000 z Howdy
(2) Extend to also output in reverse.
Enter integer: 99 Enter double:
3.77 Enter character: z Enter string: Howdy 99 3.770000 z Howdy Howdy z 3.770000 99
(3) Extend to cast the double to an integer, and output that integer.
Enter integer: 99 Enter double: 3.77 Enter character: Z Enter string: Howdy 99 3.770000 z Howdy Howdy z 3.770000 99 3.770000 cast to an integer is 3 LAB ACTIVITY 2.29.1: LAB: Warm up: Variables, input, and casting 0/5 main.c Load default template... 1 #include 2 3 int main(void) { 4 int user Int; double userDouble; // FIXME: Define char and string variables similarly printf("Enter integer: \n"); scanf("%d", &user Int); // FIXME
(1): Finish reading other items into variables, then output the four values on a single line separated by a space 19 11 12 13 14 15 16 17 18 // FIXME
(2): Output the four values in reverse // FIXME (3): Cast the double to an integer, and output that integer

Answers

Answer:

#include <stdio.h>

int main()

{

   int userInt;

   double userDouble;

   char userChar;

   char userString[50];

   

   printf("Enter integer: \n");

   scanf("%d", &userInt);

   

   printf("Enter double: \n");

   scanf("%lf", &userDouble);

   

   printf("Enter character: \n");

   scanf(" %c", &userChar);

   

   printf("Enter string: \n");

   scanf("%s", userString);

   

   printf("%d %lf %c %s \n", userInt, userDouble, userChar, userString);

   printf("%d %lf %c %s %s %c %lf %d \n", userInt, userDouble, userChar, userString, userString, userChar, userDouble, userInt);

   printf("%d %lf %c %s %s %c %lf %d %lf cast to an integer is %d \n", userInt, userDouble, userChar, userString, userString, userChar, userDouble, userInt, userDouble, (int)userDouble);

   return 0;

}

Explanation:

In addition to int and double, declare the char and string

In addition to the int, ask the user to enter the double, char and string

Print the variables in the same order as they entered

In addition to entered order, also print the variables in reverse order - type the variables in reverse order

In addition to reverse order, print the casting value of the double as int - to cast a double to an int put (int) before the variable name

Given a phrase stored in the variable phrase, write code to construct an acronym made up of the first letter of each word in the phrase. For example, the phrase 'Portable Network Graphics' would produce the acronym 'PNG'. Store the result in a variable named acronym, ensuring that it is composed of all uppercase letters. Assume that there is no whitespace on either end of the phrase and that one space character separates each word.
this is what I put but its wrong
phrase = input()
acronym = ""
lst = phrase.split()
for x in lst:
if (len(x) > 0):
acronym += x[0]
acronym=acronym.upper()
print(acronym)

Answers

Answer:

Your program is correct; it only lacks proper indentation

See Explanation

Explanation:

The only correction to your question is to rewrite using proper indents.

See below

phrase = input()

acronym = ""

lst = phrase.split()

for x in lst:

       if (len(x) > 0):

               acronym += x[0]

               acronym=acronym.upper()

print(acronym)

Note that:

You make use of indents when you have loop statements like (for) and conditional statements like (if)

Narrow margins are helpful for which task?
fitting the most content on a page
spreading out content onto more pages
aligning content in the center of a page
placing the content on the left side of a page​

Answers

Answer: A: fitting the most content on a page

Explanation:

Trust me my guy

We are developing a simulator for print queues in a network, where multiple printers can receive requests from several sources. A printer is limited in the amount of data (measured in blocks) it can print in a given time period (call the time period a "step" in the simulation). The print() method is called once for each printer in each step of the simulation. If multiple requests are sent to a printer while it is in the process of printing a document, it must store those requests in a queue, and then process them in a first-in first-out order. A printer can start printing a document at the beginning of a time step.

Required:
Complete the simulation (Doc, Printer, and PrintQueueTester). You will need to complete the Printer and Doc classes (do not add any fields to the Doc class, and do not change the API), and use the PrintQueueTester class to test your solution.

Answers

Answer:

True

Explanation:

The IT infrastructure comprises of seven major categories or domains. They are user, workstation, LAN, LAN/WAN, remote access, system /application storage, and WAN.

The user domain is the various accounts in the networked office within a workstation and other workstations in the network. The user domain provides a platform or medium to interact with the other six domains, making it possible for forensic investigation to be carried out, retrieving logs for easy account management.

PLEASE HELPP!!!!!
Select all that apply.
Proper numeric keyboarding technique includes:

1.looking at the keys
2.resting your fingers gently on the home keys
3.stiffening your fingers
4.keeping your wrist straight
5.pressing the keys squarely in the center

Answers

Answer:

1, 2 and 5

Explanation:

see picture to make sure they are in the correct order for you.

Answer:

resting your fingers gently on the home keys

keeping your wrist straight

pressing the keys squarely in the center

Cam is creating a program to display the cost of groceries. The output will be a graph showing the change in prices over several months.
Which Python module should Cam use to draw a line on the screen?

Answers

Cam could use the Turtle module to draw a line on the screen.

I hope this helps!

Answer:

turtle graphics

Explanation:

turtle graphics is the only on ethatputs a line or shape on the screen using proccessof elimination.  

What is the best location for the criteria range when filtering data?
A) immediately above the data you wish to sort
B) immediately below the data you wish to sort
C) immediately to the left of the data you wish to sort
X D) immediately to the right of the data you wish to sort

(It's NOT D)

Answers

Answer:

It's A

Explanation:

Anwser on E2020, just did it

Answer:

immediately above the data you wish to sort

Explanation:

Discuss how people navigated and communicated before the evolution of digital communication systems. What are the advantages of digital communication systems?

Answers

Answer:

The answer to this question is given below in the explanation section.

Explanation:

Before the digital communication system, early human makes communication through signs and gestures and send messages to others by a number of different methods. They could send their messages through signals with fire and smoke, drums, or whistles. The early method of communication had two limitations: first, they were restricted by the time in which communication took place. Second, they were restricted by a place that could be used only between people more or less close to each other.

They navigate through signals and signs, for navigation they search for footprint, smoke, etc to search the populated area.  The compass is the old measure they used for navigation. They travel through horses and other means of traveling they mostly use animals in their traveling for convenience. As people get advances, they used other means of sending messages to each other through letters, then the telegraph took place and telephone.

Beginning with digital communication, such as sending emails, letters, video, and audio chat make the world shrink in the global village.

People now communicate with each other in half of second with each other using new means of communication such as "s k y p e", "what s app", etc.

Now with the use of digital communication, the distance gets shrink among people. One can talk while one setting at a different corner of the world to another corner of the world in seconds. Digital communication made life simple and easy.

People can navigate through new means easily such as using "goo gl e map" etc.

Plz answer me will mark as brainliest​

Answers

Answer:

Processor is located on [tex]{\underline{\blue{\textrm{CPU}}}}[/tex]

The barcode is also called [tex]{\underline{\blue{\textrm{Universal Product code}}}}[/tex].

Discuss how people navigated and communicated before the evolution of digital communication systems. What are the advantages of digital communication systems?

Answers

Answer:

Here are the examples!!! (Sorry if they are wrong)

.Meeting new people and not having to get sick from corona.

.Chatting with your friends online!.

Explanation:

That's all i could think of.

What level do you get Super Saiyan God in Dragon ball final stand

Answers

Answer:

God Forms (SSJG - SSB KKx10) Unlocked at level 270, for 50,000 Zeni.

Explanation:

Answer:

Unlocked at level 270, for 50,000 Zeni.

Explanation:

A computer-aided drafting application would be best run on which type of device?

O Laptop
O Desktop
O Tablet
O Smartphone

Answers

A desktop because it would just work best. I’m not 100% sure this is right tho
The answer is desktop because it has the most processing power no matter what

what is wrong with my code?

using System;

namespace FavoriteNumber
{
class Program
{
static void Main(string[] args)
{

Console.Write("Enter your favorite number!: ");
int faveNumber = Console.ReadLine()
int number = Convert.ToInt32("string value")
will give 30 points to who ever is right

Answers

Answer:

namespace FavoriteNumber

{

   class Program

   {

       static void Main(string[] args)

       {

           Console.Write("Enter your favorite number!: ");

           string faveNumber = Console.ReadLine();

           int number = Convert.ToInt32(faveNumber);

           Console.Write($"Your favorite number seems to be {number}");

       }

   }

}

Explanation:

You were close. Spot the differences. A statement should end with a semicolon. Console.ReadLine() returns a string. That string is the input of what you want to convert to an int.

And of course you need to match each opening brace { with a closing brace }.

In the Scrum board, prioritizing the issue backlog is done in the ———- mode.

Answers

Answer:

The answer to this question is given below in the explanation section

Explanation:

Scrum Board is a tool that is used by the scrum teams to view the product backlog. The Scrum task board makes the sprint backlog visible for the team.

In the Scrum board, prioritizing the issue backlog is done in the Current View mode.

However, it is noted that in Scrum board there are two view modes (Tree view mode and List view mode) for the issues in the backlog. The issues that are prioritized is listed in the current view mode.  

Variables used for input are associated with what controls on a form ?​

Answers

Answer:

The answer to this question is given below in the explanation section

Explanation:

There are different forms control. for example HTML form controls are:

Text Input Controls. Checkboxes Controls. Radio Box Controls. Select Box Controls. File Select boxes. Hidden Controls. Clickable Buttons. Submit and Reset Button.

to take input from the user and store it into the variable, mostly text input form control is used.

however, you can also use text input, checkbox, radio button as a control to take input from the user and store the input value in some variables.

3.2 code practice question 1

Answers

Answer:

Not enough question content.

Explanation:

What are some methods of cyber bullying ?

Answers

Answer:

HARASSMENT

IMPERSONATION

INAPPROPRIATE PHOTOGRAPHS

WEBSITE CREATION

VIDEO SHAMING

1. A flowchart of this program. (Include the hand calculated expected output value. I pts)
2. Printout of your C++ program with a heading comment (with proper spacing and indentation)
3. Copy of a screenshot after your program is executed. (2 and 3: 2 pts cach)
4. Analyze the program and describe what makes the output to be different in plain English. ELEN 1381 Programming Assignment #4. Name Your name. Student ID : Your student ID #. Due date : Due date Purpose of the program : Calculate an average of four numbers. Section 1 : Enter four numbers. Section 2 : Calculate the average and display the answer. Section 3 : Calculate the average and display the answer. #include using namespace std; int main() int ni, n2, n3, n4, a; double b; // Section 1. cout << "Enter last digit of your Student ID : "; cin >> ni; cout << "Enter last digit of your Student ID +1: "; cin >> n2; cout << "Enter last digit of your Student ID + 2 : "; cin >> n3; cout << "Enter last digit of your Student ID + 4 : "; cin >> n4; // Section 2. a = (nl + n2 + n3 + 04) / 4; cout << "The average is : " < a << endl; 1/ Section 3. b = (nl + n2 + n3 + n4) / 4.0; cout << "The average is : " << b << endl; ; return ) // main

Answers

Answer:

See Explanation

Explanation:

1. See Attachment 1 (image file) for flowchart

2. & 3. See Attachment 2 for source file (Note that I've made some corrections on the source code)

4. What makes the outputs (a and b) to be different is that;

a calculates the average of the given parameters as a = (ni+n2+n3+n4)/4

While

b calculates a different expression = (ni+n2+n3+04)/4

They will only have the same output if n4 = 4

#include

#include

using namespace std;

const string face[] = { "Ace", "2", "3", "4", "5", "6", "7",

"8", "9", "10", "Jack", "Queen", "King" };

const string suit[] = { "Clubs", "Diamonds", "Hearts", "Spades" };

string random_card(bool verbose=false) {

string card;

card = face[ rand()%13 ];

card += " of ";

card += suit[ rand()%4 ];

if (verbose)

cout << card << "\n";

return card;

}

int main(int argc, char *argv[])

{

bool verbose = false;

int seedvalue = 0;

for (int i=1; i
string option = argv[i];

if (option.compare(0,6,"-seed=") == 0) {

seedvalue = atoi(&argv[i][6]);

} else if (option.compare("-verbose") == 0) {

verbose = true;

} else

cout << "option " << argv[i] << " ignored\n";

}

srand(seedvalue);

// declare a table called deck that keeps track of

// card faces dealt for each suit -- initialize to 0

while (1) {string card = random_card(verbose);

// reverse engineer card suit and face

// break out of loop if stopping criteria met

}

// print formatted table contents to stdout

}

write the non-existent Prog2b.cpp code and have it keep track of the order in which a card rank is observed for each suit. You do this by inserting the cards at the back of linked lists, using one list for each suit. The exception applies: each time a rank is seen again, the card gets moved to the front of the list. When the stopping criterion from Prog2a is encountered, break the infinite-loop and print the contents of each linked list to stdout as shown below.

Add an array of linked lists: the length of the array is fixed at 4 like before, while the length of each linked list varies from suit to suit. Each new card is added to the appropriate list thru use of an insert() function. Declare a list class based on a single linked list. The list class needs to define a private node datatype, and it must include a constructor for properly initializing an empty list, a destructor for deallocating all the nodes in a list as well as the list itself, and the mentioned insert function which works as described next; no other list class functions are needed. Overload operator<<() used by ostream and have it print the contents of the list. Since access is needed to private data members, make the overloaded output operator a friend of the list class. See the code handouts for how to set this up.

The list::insert() function is where the fun work takes place. The function takes a single integer argument, namely, the rank index of a card where index refers to the position of the rank in the global rank string array. If the rank index is not held by any node in the linked list, a new node is created and added to the end of the list that stores the rank index value. However, if a node is found to already hold the present rank index argument, that node is moved to the front the linked list. That is, the node in question is unlinked from where it is and inserted after the head node.

Hint: You are using a single linked list which means you cannot go back once you have a match on the rank index. One option is to look ahead instead of advancing and then taking a look a the rank index. Another option is to maintain two pointers, namely, one pointing to previous node and one pointing to current node.

Hint: Write generic code that works under all circumstances rather than have several codes for special cases. For example, write the insert() function so that it can handle a rank match regardless of where the matching node resides in the list. Draw a sketch of the different scenarios that need to be handled and infer from it how to do it generically.

Prog2b example output

UNIX> ./prog2b
Clubs : 10 6 Queen King 9 Jack **
Diamonds : Jack 9 6 Ace 3 8
Hearts : 9 3 King 7 Jack
Spades : Queen Ace Jack
UNIX>
UNIX> ./prog2b -seed=140
Clubs : 10 Jack King 4 2 Ace 7 6 3 8
Diamonds : King 3 Ace 9 Queen 5 10 8 7 2 Jack **
Hearts : Jack 2 10 7 6 3 Ace 5 4
Spades : 6 5 Jack 4 9 Queen 2

Answers

Answer:

dang sis did u really have to but all of that

1.5 code practice question 3

Answers

Answer: What the hell is that 243 suppose to be

Explanation:uhg

Why might a variable used for output have to be of a different type then a variable used for input?​

Answers

Answer:

You may use a different variable type for input in order to process the data appropriately and may use a different variable type to accommodate your program.

Explanation:

Your input may have to be different then output varying on what data you are processing.

For example, just like the last question you asked about calculating the area of the rectangle, your input MUST be converted to a different a numerical data type (i.e int or float) in order to do the math.

Based on your last question, if we didn't convert your input into a string your results wouldn't add the numbers together but only concatenate them. If I typed 3 & 5 as length & width, I would get 35 instead of 15.

Now another example is using functions (or methods whatever you want to call them), your input can be one thing and outputs another.

Let's say I want a function to tell me if I am smart. The way I want it to determine if its smart is by inputting my GPA into it, which is a numerical value. So the function would look something like this:

Code (Python)

def IsSmart(gpa):

  if (gpa >= 4):

       return True

  else

       return False

As you can see I am inputting a numerical value and it is outputting a boolean value. I can use this in a if else chain to spit out an output to the user.

What is an example of conditional formatting? Cells in a row have a yellow background. Cells in a range with values under 10 have a red background. Cells in a column have green text. Cells in a worksheet have borders around their edges.

Answers

Answer:

Cells in a range with values under 10 have a red background.

Explanation:

Just took it :)

Answer:

A. Cells in a range with values under 10 have a red background.

Explanation: edge 2022

Other Questions
The graphs for the functions f(x) = x3 and g(x) = x3 are shown in the graph below. Describe the transformations of a parent function to obtain the graphs of f(x) and g(x). in which of the following ways can mass spectrometry be used to determine the sequence of large proteins? Provide a detailed information regarding Harley-Davidson's(Motorcycle Producer) SCM system including all upstream anddownstream participants. 20 PT PLZZ HELP ASAPC=4.95+ 3.99b 3.99 per book plus 4.95 fee paid once a month Create a graph of your equation For a certain company, the cost for producing x items is 50x+300 and the revenue for selling x items is 90x0.5x2.The profit that the company makes is how much it takes in (revenue) minus how much it spends (cost). In economic models, one typically assumes that a company wants to maximize its profit, or at least wants to make a profit!Part a: Set up an expression for the profit from producing and selling x items. We assume that the company sells all of the items that it produces. (Hint: it is a quadratic polynomial.)Part b: Find two values of x that will create a profit of $300.The field below accepts a list of numbers or formulas separated by semicolons (e.g. 2;4;6 or x+1;x1). The order of the list does not matter. To enter a, type sqrt(a).x=Part c: Is it possible for the company to make a profit of $15,000?FeedbackThis is a typical model used in "microeconomics", the economic study of a firm.In your Discussion post, don't just post your final answers. It's very important that you explain to your classmates how you arrived at those answers.It helps to start by choosing good names for the variables. It would make sense here to have x be the number of items, C be the Cost of producing x items, R be the Revenue from selling x items, and P be the Profit from producing and selling x items.Part a: Write expressions for C and R, the cost and revenue, in terms of the variable x. The profit P that a company makes is the revenue minus cost, or P=RC. You need to write P also in terms of the variable x.Part b: Finding two production/sales levels x that create a profit of $300 means solving the equation P=$300. Use your formula for P from Part a and apply what you learned about solving quadratic equations in Module 2 to solve for x. You saw several different methods (factoring, completing the square, quadratic formula, etc.) and can use whichever one you choose.Part c: This is similar to Part b, but instead you need to solve the equation P=$15,000. Hint - the quadratic equation might be the easiest method for this part AWARDING BRAINLIEST HLPE PLEASE! SHOW WORK ALSOComplete each statement from the information given and the triangle criterion you used. If the triangles cannot be shown to be congruent, leave the box for the second triangle blank and choose for reason Cannot be determined. CAT ______ by ______ someone please finish and explain this! i'm giving brainliest, tysm :) Krista purchased a second-hand whipping machine without ever having seen it. Amy, the seller, had described it as "new the previous year" and "used it to bake only 2 or 3 cakes". The whipping machine was very old. Krista paid for it in cash but was not happy upon viewing the actual whipping machine.Based on the Sale of Goods Act 1957, advise Krista. ( 30 Marks ) If the offices of both President and Vice President become vacant, who becomes President?Speaker of HouseSecretary of StateSecretary of DefensePresident pro tempore of the Senate From your experience, what does a person's "cultural fit" with the organization mean? Discuss a time you have experienced either cultural fit or non-fit in terms of Organizational Culture.Please I need at least 250 words. Download the Demo1901.txt file. This is the same file used in the previous exam. Import the file using the attached codes but modify it to treat ALL dates as character variables. SAS doesn't need to know these values are dates, at least for now. Call this dataset "Demog" 2) Download and import the REAC19Q1.txt file. Call this dataset "AE" and keep only primaryid and PT variables. Create labels for these variables, only What does the quote men would say of him that up he went and down he came without his eyes from paragraph 33 mean in the context of the passage locate and cite the colorado jury instructions defining at-will employment You bought a stock one year ago for $51.25 per share and sold it today for $59.96 per share. It paid a $1.74 per share dividend today. a. What was your realized retum? b. How much of the retum came from dividend yield and how much came from capital gain? a. What was your realized return? The realized return was \%. (Round to two decimal places.) You lose four points each time you attend gym class without sneakers. You forget your sneakers threetimes. What integer represents the change in your points? Harry's Hardware uses a perpetual inventory system. During September 20X3, the following purchases and sales transactions occurred:i. Goods sold on credit for $4 000 plus GST (cost $3 280) were returned.ii. Purchased goods on account for $5 000 plus GST;iii. Paid for the balance of the purchase in time to receive a discount of 2% of the purchase price; andiv. Sold goods costing $15 300 for $22 600 plus GST. Cash of $10 000 was received with the balance on credit.Required: Prepare general journal entries to record the above transactions. PLS if you answer right Ill like and give stars PLSSP(x)=2x^4-x^3+2x^2-kP(x) divided by (x+1) has a remainder of 2What is the value of k? What is the value of x in the equation below?11.9 - 0.8x = 4.5A--6.6B9.25 17.2D20.5 The box plots display data collected when two teachers asked their classes how many pencils they lose in a school year.A box plot uses a number line from 5 to 47 with tick marks every one unit. The box extends from 8 to 14 on the number line. A line in the box is at 11. The lines outside the box end at 7 and 45. The graph is titled Mr. Johnson's Class, and the line is labeled Number Of Pencils.A box plot uses a number line from 0 to 51 with tick marks every one unit. The box extends from 12 to 21 on the number line. A line in the box is at 14.5. The lines outside the box end at 0 and 50. The graph is titled Mr. Simpson's Class, and the line is labeled Number Of Pencils.Which class lost the most pencils overall based on the data displayed? Mr. Simpson's class; it has a larger median value 14.5 pencils Mr. Johnson's class; it has a larger median of 11 pencils Mr. Simpson's class; it has a narrow spread in the data Mr. Johnson's class; it has a wide spread in the data what is one of the main reasons for the severe shortage of certain goods after a natural disaster?Group of answer choicesStores hide goods after the disaster and refuse to sell themThere is a demand increase but price gouging laws dont allow prices to riseThe disaster usually destroys most of the available goodsThe government strictly rations most goods after the disaster