Python Code to be wriiten:
Will mark as brainliest if correct!
A bunny can hop at most 50 centimetres far. It wants to cross to the other side of the river, but it cannot swim. So the only hope is to hop on the rocks on the river, which are positioned in a straight line. The positions of the rocks are measured from the start location, assuming that the bunny starts at the 0 cm mark. The opposite bank could be treated as a big rock. It is the final rock in the tuple of rocks.

In the Figure below, the rocks are at locations 32, 46, 70, 85, 96, 123, and the opposite riverbank is at location 145.

The bunny will jump as far as it could for each hop. What is the smallest number of jumps it needs to take to reach the other side of the river? For the above example, it needs to make 3 jumps, as shown in the diagram above.

You may assume that there are at most 20 rocks (including the opposite bank).

Write a function rabbit that takes in a tuple representing the locations of the rocks. Your function should return the minimum number of jumps needed, or -1 if it is not possible for the bunny to reach the other side of the river. You may assume that the locations of the rocks in the tuple are valid (bigger than 0) and they are sorted in ascending order.

def rabbit(rocks):
# Fill in your code here

Test Cases:
rabbit((32, 46, 70, 85, 96, 123, 145)) 3
rabbit((40, 70, 150, 160, 180)) -1
rabbit((30, 70, 75, 120, 160, 170, 180, 190, 200, 246, 258)) 7
rabbit((51, 52, 53, 54, 55, 56, 57, 58)) -1
rabbit((50, 51, 101, 102, 152, 153, 203, 204, 254, 255, 305, 306, 356, 357, 407)) 15

Answers

Answer 1

Using the knowledge in computational language in python it is possible Write a function rabbit that takes in a tuple representing the locations of the rocks.

Writting the code:

def rabbit(rocks):

   jumps = 0

   prev = 0

   cursor = 0

   i = 0

   while i < len(rocks):

       rock = rocks[i]

       if rock - prev < 50:

           cursor = rock

           i += 1

           continue

       elif rock - prev >= 50 and prev != cursor:

           jumps += 1

           prev = cursor

           continue

       else:

           return -1

   if i == len(rocks):

       rock = rocks[i-1]

       if rock - prev <= 50:

           jumps += 1

   if jumps == 0:

       return -1

   return jumps

See more about python at brainly.com/question/29897053

#SPJ1

Python Code To Be Wriiten:Will Mark As Brainliest If Correct!A Bunny Can Hop At Most 50 Centimetres Far.

Related Questions

Jackson is visiting his cousin over summer vacation. While visiting, he decides to check his email. Jackson notices that the computer he is working on is incredibly slow and is connected to the network through a series of telephone lines. He is also unable to use the home telephone while he is connected to the internet. Which of the following types of network connection is Jackson using?

A.
digital subscriber line

B.
cable broadband line

C.
fiber optics line

D.
dial-up internet line

Answers

Note that in this case, Jackon is using a "dial-up internet line" (Option D)

What is a dial-up internet line?

Dial-up Internet access is a type of Internet access that uses the public switched telephone network's infrastructure to connect to an Internet service provider by calling a phone number on a traditional phone line.

Dial-up The Internet has been available since the 1980s through public providers such as NSFNET-connected institutions. In 1989, the BBC offered Internet connection through Brunel University in the United Kingdom. Pipex in the United Kingdom and Sprint in the United States were the first to commercially provide dial-up in 1992.

Learn more about dial-up internet line:
https://brainly.com/question/3521554
#SPJ1

Given a string, return the character that appears
the maximum number of times in the string. The
string will contain only ASCII characters, from the
ranges ('a'-'z','A'-'Z','0'-'9'), and case matters. If there
is a tie in the maximum number of times a
character appears in the string, return the
character that appears first in the string.

Answers

To find the character that appears the maximum number of times in a given string, you can follow these steps:

1. Initialize an empty dictionary to store the count of each character in the string.

2. Iterate through each character in the string.

3. If the character is already present in the dictionary, increment its count by 1. Otherwise, add the character to the dictionary with a count of 1.

4. After counting the occurrences of each character, find the character(s) with the maximum count.

5. If there is a tie for the maximum count, return the character that appears first in the string.

6. If there is no tie, return the character with the maximum count.

By implementing this algorithm, you can find the desired character efficiently. Remember to consider case sensitivity if required, as uppercase and lowercase letters are treated as distinct characters.

For more such questions on string, click on:

https://brainly.com/question/30392694

#SPJ11

A computer network can share printers and software A)True B)False​

Answers

Answer:

A) True

Explanation:

A computer network can share printers and software by using a feature called printer sharing.

What does printer sharing do?

Printer sharing allows multiple computers to use a single printer over a network. To share a printer on a network, you need to connect it directly to one of the computers on the network or to a print server that is connected to the network

Answer:

A) True

Explanation:

A computer network can share printers and software by using a feature called printer sharing.

What does printer sharing do?

Printer sharing allows multiple computers to use a single printer over a network. To share a printer on a network, you need to connect it directly to one of the computers on the network or to a print server that is connected to the network

Could YOU Please help me out of this question This is how I started typing but at the end I got stuck My half of the answers I attached. please Help I will give you brainiest


we will work on text processing and analysis. Text analyzers could be used to identify the language in which a text has been written (language detection), to identify keywords in the text (keyword extraction) or to summarize and categorize a text. You will calculate the letter (character) frequency in a text. Letter frequency measurements can be used to identify languages as well as in cryptanalysis. You will also explore the concept of n-grams in Natural Language Processing. N-grams are sequential patterns of n-words that appear in a document. In this project, we are just considering uni-grams and bi-grams. Uni-grams are the unique words that appear in a text whereas bi-grams are patterns of two-word sequences that appear together in a document.


Write a Java application that implements a basic Text Analyzer. The Java application will analyze text stored in a text file. The user should be able to select a file to analyze and the application should produce the following text metrics:


1. Number of characters in the text.

2. Relative frequency of letters in the text in descending order. (How the relative frequency that you calculated compares with relative letter frequencies in English already published?)

3. Number of words in the text.

4. The sizes of the longest and the shortest word.

5. The twenty most repeated uni-grams (single words) in the text in descending order.

6. The twenty most repeated bi-grams (pairs of words) in the text in descending order.


Test your program in the file TheGoldBug1.txt, which is provided.

Answers

The given program based on the question requirements is given below:

The Program

public static void analyzeChar(String text)

{

text = text.toLowerCase();

char [] characters = new char[26];

int [] rep =new int[26];

//populate the array of characters

char ch = 'a';

for (int i =0; i < characters.length; i++)

{

characters[i] = ch;

ch++;

}

itz72

//System.out.println(Arrays.toString(characters));

//System.out.println(Arrays.toString(rep));

//how many times each characters repeats

for (int i =0 ; i < text.length (); i++ )

{

ch = text.charAt(i);

if(ch>= 'a'&& ch<= 'z')

{

rep[(int)(ch-'a')]++;

}

itz72

}

//show the number of repetitions

for (int i = 0; i < rep.length; i++)

{

System.out.println("character" + characters[i] + "reapeats"+ rep[i]);

}

}

itz72

public static void calcNumChar(String text)

{

System.out.println("The number of characters is: " + text.length());

}

public static String getText(String fileName) throws IOException

{

String line = "", allText = "";

//open the file

File file = new File(fileName);

Scanner inputFile = new Scanner(file);

//read the file

while(inputFile.hasNext())

{

line = inputFile.nextLine();

//System.out.println(line);

allText=allText + (" " + line);

}

itz72

//close the file

inputFile.close();

return allText;

}

public static String getFilename()

{

String file;

Scanner kb = new Scanner(System.in);

System.out.print("Enter the name of the file: ");

file = kb.nextLine();

return file;

}

}

This script contains numerous functions that aid in the examination and manipulation of written materials. This program determines the incidence of every letter present in the supplied text, tallies the overall character count, and includes the ability to import text from a file.

Read more about programs here:

https://brainly.com/question/26497128

#SPJ1


What are examples of object types that can be viewed in the Navigation pane? Check all that :

commands
forms
options
queries
tasks
tables

Answers

Answer:

2.) Forms

4.) Queries

6.) Tables

Explanation:

Explain how image classification is done using the AI process.

Answers

Image classification using AI involves acquiring labeled or unlabeled images, training a neural network model with these images, extracting features from the images, and classifying them based on those features.

Image classification is a technique used in artificial intelligence (AI) to identify and categorize objects or features in an image. The process of image classification using AI involves several steps, starting with the acquisition of labeled or unlabeled images.

The labeled images are used to train a model, which is a neural network that learns to identify patterns in the images. The neural network uses algorithms to extract features from the images and then classifies them based on those features.

The AI process involves feeding the model with a large number of images to learn from. The model is trained by comparing the features it extracts from the images with known categories, and adjusting the weights of the neurons to improve its accuracy. Once the model is trained, it can be used to classify new images by feeding them through the network, and the output is the predicted category.

For more such questions on  artificial intelligence, click on:

https://brainly.com/question/30073417

#SPJ11

An equal-tangent sag equal tangent vertical curve is designed for 45 mi/h. The low point is 237 ft from the PVC at station 112 + 37 and the final offset at the PVT is 19.355 ft. If the PVC is at station 110 + 00, what is the elevation difference between the PVT and a point on the curve at station 111 + 00?

Answers

Answer:

vertical and I have a great day of school

5 different mobile graphics application

Answers

Answer:

1.  Adobe Photoshop Mix

2. Adobe Capture

3. Autodesk Sketchbook

4. Adobe Spark Post

5.  Behance: Photography Graphic Design, Illustration

Explanation:

From my research, there are more than 5 different graphic applications for graphic designers that will make your life easier, depending on what you want to achieve, then you select a particular mobile graphic tool.

Here is the problem specification: An Internet service provider has three different subscription packages for its customers: Package A: For $9.95 per month 10 hours of access are provided. Additional hours are $2.00 per hour. Package B: For $14.95 per month 20 hours of access are provided. Additional hours are $1.00 per hour. Package C: For $19.95 per month unlimited access is provided. Write a program that calculates a customer's monthly bill. It should ask which package the customer has purchased and how many hours were used. It should then display the total amount due. Input Validation: Be sure the user only selects package A, B or C. Also, the number of hours used in a month cannot exceed 744. Use switch.

Answers

Answer:

In C++:

#include <iostream>

using namespace std;

int main(){

   int hour; char pkg; float bill = 0;

   cout<<"Package: "; cin>>pkg;

   cout<<"Hour: "; cin>>hour;

   if(hour<=744 && hour >=0){

       switch (pkg) {

           case 'A':

               bill = hour * 9.95;

               if(hour >10){bill = 10 * 9.95 + (hour - 10) * 2;}

           break;

           case 'B':

               bill = hour * 14.5;

               if(hour >10){bill = 20 * 14.5 + (hour - 20) * 1;}

           break;

           

           case 'C':

               bill = 19.95;

           break;

           

           default:

               cout << "Package must be A, B or C";}

cout<<"Total Bills: $"<<bill; }

else{ cout<<"Hour must be 0 - 744"; }

return 0;

}

Explanation:

This declares all variables:    int hour; char pkg; float bill=0;

This prompts the user for package type:  cout<<"Package: "; cin>>pkg;

This prompts the user for number of hours:    cout<<"Hour: "; cin>>hour;

This checks if hour is between 0 and 744 (inclusive)

   if(hour<=744 && hour >=0){

If true, the following is executed

A switch statement to check valid input for package

       switch (pkg) {

For 'A' package

           case 'A':

Calculate the bill

               bill = hour * 9.95;

               if(hour >10){bill = 10 * 9.95 + (hour - 10) * 2;}

End of A package:            break;

For 'B' package

           case 'B':

Calculate the bill

               bill = hour * 14.5;

               if(hour >10){bill = 20 * 14.5 + (hour - 20) * 1;}

End of B package:            break;

For C package            

           case 'C':

Calculate bill:                bill = 19.95;

End of C package:            break;

If package is not A, or B or C

           default:

Prompt the user for valid package                cout << "Package must be A, B or C";}

Print total bills: cout<<"Total Bills: $"<<bill; }

If hour is not 0 to 744: else{ cout<<"Hour must be 0 - 744"; }

Match the inventor with the innovation they created.

J. C. R. Licklider
✔ Galactic network

Sergey Brin and Larry Page
✔ Search engines

Tim Berners Lee
✔ Hypertext

Vinton Cerf
✔ Domain name system management

Answers

The way it is written and paired with, is correct.

f a user's computer becomes infected with malware and used as part of a botnet, which of the following actions can be initiated by the attacker? (Select all that apply.)

Launch a Distributed Denial of Service (DDoS) attack
Launch a tailgating attack
Launch a mass-mail spam attack
Establish a connection with a Command and Control server

Answers

The actions that can be initiated by the attacker are

Establish a connection with a Command and Control serverLaunch a mass-mail spam attackLaunch a Distributed Denial of Service (DDoS) attack.

What is malware?

Malware is a catch-all term for viruses, trojans, and other damaging computer programs that threat actors use to infect systems and networks and access sensitive data. Malware is software designed to obstruct a computer's regular operation.

The computer that has been infected and joined a botnet must create a network connection to the bot-"Command net's and Control" server. After that, it might take part in whichever attack the control orders.

Therefore, the correct options are:

Establish a connection with a Command and Control serverLaunch a mass-mail spam attackLaunch a Distributed Denial of Service (DDoS) attack.

Learn more about malware:

brainly.com/question/22185332

#SPJ1

5. The operating system has two components
a. Software and Hardware
c. Shell and Kernel
b. Sof
d. File​

Answers

This is a very oddly worded question. However, based on my knowledge on computers (as I have built one), I believe the correct answer is:

A- Software and hardware.

Computers are an operating system made up of the CPU, GPU, Ram, storage, motherboard, etc. On the other hand, in order to be able to use a computer properly, you have to buy a operating system, such as windows 7, or windows 10 (recent and most used operating system). Sorry if I get this wrong, but if I helped you, please mark as brainliest!

О OF
Types icts commonly
in education.
used​

Answers

Answer:

The types of the itcs can be defined as follows:

Explanation:

It stands for the information and communication technology, which is used to comprises products that are a store, process, pass, transform, replicate or receive digital communications. 

It applies to all technology of interaction, such as the Internet, wireless networks, devices, laptops, middleware, video - conferencing, social media, and other software and services in media, and the four types in which it is used in education can be defined as follows:

(i) networking for education

(ii) Web-based education

(iii) mobile education

(iv) facilities for the classroom

who is the father of computer?
1.Charles Babbage 2.James Waat​

Answers

Answer:

its 1 Charles babbage

Explanation:

shjdjdjdjdjdj

Answer:

Si Charles Babbage,

Explanation:

FRS ay isang Ingles na matematiko, pilosopo, imbentor, at inhinyerong mekanikal na nagpanimula ng konsepto ng isang naipoprogramang kompyuter. Nakatanghal ang mga bahagi ng kanyang hindi pa buong mga mekanismo sa Museo ng Agham sa London.

PLEASE ANYONE HELP ME. PLEASE I BEG OF YOU.
Give an illustration of the agile model in game development.

Answers

The illustration of the Agile Model in Game Development is expressed below. With it, game developers can efficiently manage risks, respond to player preferences and deliver a high-quality game that meets market demand.

How does the Agile Model contribute to game development?

The Agile Model as commonly used in game development, is characterized by its iterative and flexible approach. It focuses on delivering frequent increments of playable content and incorporating feedback throughout the development process.

The Game development teams using Agile work in short sprints typically use two to four weeks long where they plan, develop, test and release small portions of the game. This allows for continuous improvement, adaptability to changes and collaboration between developers, designers, and stakeholders.

Read more about agile model

brainly.com/question/30126132

#SPJ1

The 1D array CustomerName[] contains the names of customers in buying electronics at a huge discount
in the Ramadan Sales. The 2D array ItemCost[] contains the price of each item purchased, by each
customer. The position of each customer’s purchases in the two array is the same, for example, the
customer in position 5 in CustomerName[] and ItemCost[] is the same. The variable Customers
contains the number of customers who have shopped. The variable Items contains the number of items
each customer bought. All customers bought the same number of products with the rules of the sale
dictating they must buy 3 items with a minimum spend of 1000AED. The arrays and variables have
already been set up and the data stored.
Write a function that meets the following requirements:
• calculates the combined total for each customer for all items purchased
• Stores totals in a separate 1D array
• checks to make sure that all totals are at least 1000AED
• outputs for each customer: – name – combined total cost – average money spent per product
You must use pseudocode or program code and add comments to explain how your code works. You do
not need to initialise the data in the array.

Answers

Here's a Python code that meets the requirements you mentioned:

python

Copy code

def calculate_totals(CustomerName, ItemCost, Customers, Items):

   # Create an empty array to store the totals for each customer

   total_cost = []

   # Iterate over each customer

   for i in range(Customers):

       # Get the start and end indices of the items for the current customer

       start_index = i * Items

       end_index = start_index + Items

       # Calculate the total cost for the current customer

       customer_total = sum(ItemCost[start_index:end_index])

       # Check if the total cost is at least 1000AED

       if customer_total < 1000:

           print("Total cost for customer", CustomerName[i], "is less than 1000AED.")

       # Calculate the average money spent per product

       average_cost = customer_total / Items

       # Add the customer's total cost to the array

       total_cost.append(customer_total)

       # Print the customer's name, total cost, and average money spent per product

       print("Customer:", CustomerName[i])

       print("Total Cost:", customer_total)

       print("Average Cost per Product:", average_cost)

       print()

   # Return the array of total costs for each customer

   return total_cost

# Example usage:

CustomerName = ["John", "Mary", "David", "Sarah"]

ItemCost = [200, 300, 400, 500, 600, 700, 800, 900, 1000, 1100, 1200, 1300]

Customers = 4

Items = 3

calculate_totals(CustomerName, ItemCost, Customers, Items)

This code takes the CustomerName array and ItemCost array as inputs, along with the number of customers Customers and the number of items per customer Items. It calculates the total cost for each customer, checks if the total is at least 1000AED, calculates the average cost per product, and prints the results for each customer. The totals are stored in the total_cost array, which is then returned by the function.

Learn more about python on:

https://brainly.com/question/30391554

#SPJ1

What is open source software? ​

Answers

Answer:

Open source software is free, modifiable, and is able to be redistributed. It is beneficial to those wanting  to customize the software to suit their purposes as it can be easily shared and redistributed.

Drag each option to the correct location on the image.
faulty cables remove and reinsert cables blinking lights
ensuring that the computer is
drawing power from the outlet
restarting the computer
NETWORK ISSUES
network collision
TROUBLESHOOTING TECHNIQUES
4

Answers

Here is the correct placement of the options on the image:

NETWORK ISSUES

* faulty cables

 * remove and reinsert cables

* blinking lights

* ensuring that the computer is drawing power from the outlet

* restarting the computer

* network collision

How to explain the information

If the network cable is faulty, it can cause network issues. To fix this, remove and reinsert the cable.

If the network lights on your computer or router are blinking, it can indicate a problem with the network connection. To fix this, check the cables and make sure that they are properly plugged in.

Ensuring that the computer is drawing power from the outlet: If the computer is not drawing power from the outlet, it will not be able to connect to the network. To fix this, make sure that the power cord is plugged in properly.

Learn more about network on

https://brainly.com/question/1326000

#SPJ1


Output devices include:
A) Printers, and Monitors
B) CPU
C) System Unit
D) None of the above

Answers

Answer:

CPU IS TH ANSWER BECAUSE IT IS OUT

Methods ii.) Define and implement a method that takes a string array as a parameter and returns the length of the shortest and the longest strings in the array i.) Write a method that take an integer array as a parameter and returns the sum of positive odd numbers and sum of positive even numbers. iii.) Implements the sequential search method that takes and array of integers and the item to be search as parameters and returns true if the item to be searched in the array, return false otherwise

Answers

Answer:

Explanation:

Well I am sorry I don't know the answer anyway.

Given : A=(1,2), B(x,y,z), and C= (3,4). Find: A X B X C

Answers

Answer:

= {(1, x, 3), (1, x, 4), (1, y, 3), (1, y, 4), (1, z, 3), (1, z, 4), (2, x, 3), (2, x, 4), (2, y, 3), (2, y, 4), (2, z, 3), (2, z, 4)}

Explanation:

A(1,2)

B(x,y,z)

C=(3,4)

Find : A X B X C

= (1, 2) X ( x, y, z) X (3, 4)

= {(1, x), (1, y), (1, z), (2, x), (2, y), (2, z)} × (3, 4)

= {(1, x, 3), (1, x, 4), (1, y, 3), (1, y, 4), (1, z, 3), (1, z, 4), (2, x, 3), (2, x, 4), (2, y, 3), (2, y, 4), (2, z, 3), (2, z, 4)}

In MS Excel, a function is written as =FUNCTION_NAME(_____________________).​

Answers

Explanation:

A function is a predefined formula that performs calculations using specific values in a particular order. All spreadsheet programs include common functions that can be used for quickly finding the sum, average, count, maximum value, and minimum value for a range of cells. In order to use functions correctly, you'll need to understand the different parts of a function and how to create arguments to calculate values and cell references.

1
When collection of various computers
look like a single coherent system to its
client, then it is called​

Answers

Answer:

The appropriate answer is "Distributed system".

Explanation:

Whenever used by linking several autonomous computers as a single system, considered as distributed system. It could be consist of several kinds of  mainframes, processors as well as stationary machines, it can be programmed. A distributed machine has massive program modules, which operate as a single device on many machines.

List and fully describe at least 3 examples of input devices and how they are applied in the real world. (In separate paragraphs.)

Answers

Answer:

1. Mouse

2.Graphic Tablet

3.Keyboard

Explanation:

1. A computer mouse (plural mice, rarely mouses) is a hand-held pointing device that detects two-dimensional motion relative to a surface. This motion is typically translated into the motion of a pointer on a display, which allows a smooth control of the graphical user interface of a computer.

2.Graphic tablets, because of their stylus-based interface and ability to detect some or all of pressure, tilt, and other attributes of the stylus and its interaction with the tablet, are widely considered to offer a very natural way to create computer graphics, especially two-dimensional computer graphics

3.A keyboard is for putting information including letters, words and numbers into your computer. You press the individual buttons on the keyboard when you type. The number keys across the top of the keyboard are also found on the right of the keyboard. The letter keys are in the centre of the keyboard.

why is it important to give files name that are descriptive of their content​

Answers

Answer:

Provide a descriptive document file name and title

A unique, descriptive file name helps individuals understand the general topic of a document. Include similar information when writing the title of the document, and apply appropriate punctuation, e.g., no underscores.

Explanation:

Please give thanks to all my answers and please mark as brilliant and please follow me

When is a table the most effective way to present information?
A. When you want to show the parts of a whole.
B. When you want to make many details available in an organized
way.
OC. When graphs are more expensive to create.
D. When you want to show how parts fit together.

Answers

The most effective way to present information in a table is when you want to make many details available in an organized way. (Option B)

What is a table in database management?

Tables are database objects that hold all of the information in a database. Tables logically arrange data in a row-and-column structure comparable to spreadsheets. Each row represents a distinct record, and each column represents a record field.

A table in Excel is a rectangular range of data that has been defined and designated in a certain way. To demonstrate, consider the following two rectangular data ranges. Both ranges contain identical data, but neither has been classified as a table.

Learn more about table  at:

https://brainly.com/question/12151322

#SPJ1

Complete the sentence about information censorship.
Cybersurveillance refers to how technology is used to
people's internet activity.

Answers

Cyber surveillance refers to how technology is used to observe people's internet activity.

How is this used?

The utilization of technology to observe and regulate individuals' online behavior, commonly for the purpose of restricting or inhibiting access to particular data, is known as cyber surveillance.

The process of gathering, examining, and storing electronic data enables influential bodies or authorities to monitor people's cyber activities, govern entrance to particular websites or channels, and alter or screen content.

The extensive surveillance and regulation measures can violate privacy and compromise freedom of speech, leading to apprehensions about misuse of authority and suppression of open communication and information exchange in the era of technology.

Read more about Cyber surveillance here:

https://brainly.com/question/31000176

#SPJ1

bills is replacing a worn-cut cable to his power table saw.what type of cable is he most likely using ?
A.PSC
B.SO
C.CS
D.HPD

Answers

Bill is replacing a worn-cut cable for his power table saw.  is using is A. PSC (Portable Cord).

What is the bills?

Working with frayed cables can be dangerous and may act as a form of a risk of electric shock or other hazards. To make a safe and successful cable replacement, there are some general steps Bill can follow.

A is the most probable  type of cable he is utilizing from the provided choices. A type of cord that can be easily carried or moved around. Flexible and durable, portable cords are frequently utilized for portable power tools and equipment.

Learn more about bills from

https://brainly.com/question/29550065

#SPJ1

To be done in C#
• Description of the class
• Class properties for each attribute listed with the class with public get and set accessors
• Implement other methods as described in the class descriptions/UML diagram

The main application must do the following
• Print a line that states "Your Name - Week 1 Composition Performance Assessment"
Create 2 instances of the Automobile class using parameters of your choosing
Add at least 2 tires to the instances
Add some tires by passing a Tire object to the AddTire method
Add some tires by passing the parameters to create a Tire object to the AddTire method

Print one of the instance's properties to the console using the ToString method

Print one of the instance's properties to the console using the GetInfo method

Print the following for one of the instances using property accessors (all information must be included; formatting and order is up to you):
Make, Model, Color, Body Style, Engine Information, Number of Cylinders, Approved Gas Type, Fuel Injected?

Tire Information for each tire
Manufacturer, Tire Size, Max Pressure, Min Pressure, and Type

Class Descriptions & Additional Requirements
Class Automobile will be the class that is composed of other classes and will have the properties and methods described below
Properties:
Make - type string, the automobile manufacturer (e.g., Ford, Jaguar)
Model-type string, the model description (e.g., Explorer, Navigator)
Color - type string, the car's color
BodyStyle - type string, car style description (e.g., Sedan, SUV)
EngineInfo - type Engine, engine information object (see Engine Class for details)
Tires - collection of type Tire, list/array of the tire objects included in the automobile

Methods:
GetInfo() - gets formatted (you determine the format) class information including: Make, Model, Color, Engine Cylinder Count, Fuel Injected or Not, and Number of Tires
ToString() - gets all class information, you determine the format
AddTire(Tire) - adds a tire object to the Tires property
AddTire(string, string, int, int, string) - adds a tire object to the Tires collection via parameters

Class Engine
Properties
Cylinders - type integer, the number of cylinders the engine has
GasType - type string, approved type of fuel, e.g., Diesel, Unleaded 87 octane, Ethanol Free
Fuellnjected - type bool, whether the engine is fuel injected or carburetor-based

Methods
No additional required methods; you may create additional methods at your discretion

Class Tire
Properties
Manufacturer - type string, the tire manufacturer, e.g., Continental, Pirelli
Size - type string, the tire size, e.g., 185/60R13, 165/50R15
MaxPressure-type integer, the maximum pressure for the tire
MinPressure - type integer, the minimum pressure for the tire
Type - type string, the type of tire, e.g. All Season Radial, Studded Snow, Spare

Methods
No additional required methods; you may create additional methods at your discretion

Automobile 1 is to use ToString()
Automobile 2 is to use GetInfo()

Answers

Practice with examples is the most effective way to learn C++. Examples on fundamental C++ ideas can be found on this page. It is encouraged that you use the examples as references and test the concepts on your own and Programme.

Thus, All of the programs on this page have been tested, so they should all run well.

Examining a ton of sample programs is one of the finest ways to learn how to program in a new language. It is recommended to copy and paste each of the programs listed below into a text file before compiling them.

Try the experiments after that. You will become more familiar with various C++ features by expanding these example programs, and you'll feel more at ease when it comes time to build programs from scratch.

Thus, Practice with examples is the most effective way to learn C++. Examples on fundamental C++ ideas can be found on this page. It is encouraged that you use the examples as references and test the concepts on your own and Programme.

Learn more about Programe, refer to the link:

https://brainly.com/question/14368396

#SPJ1

What is the output
print( ‘You are’, age, ‘years old. ‘)

Answers

The output print(‘You are’, age, ‘years old.’) function is a useful tool for programmers looking to display a person's age as part of a string of text. It is a straightforward function that can be easily incorporated into a variety of Python programs.

The outputprint(‘You are’, age, ‘years old.’) is a Python function that outputs a string of text that includes the variable ‘age’. The function prints the phrase ‘You are’, followed by the value of the variable ‘age’, and ends with the phrase ‘years old.’ For example, if the variable ‘age’ is assigned the value of 25, then the output of the function would be ‘You are 25 years old.’

This function is commonly used in programs that involve age calculations or when displaying a person's age. It is a simple way to incorporate the value of a variable into a text string and output it to the console or screen.

For more such questions on Python function, click on:

https://brainly.com/question/25755578

#SPJ11

Other Questions
what claims does president Truman make about why the United States must be the nation to provide the aid Use an ordinary truth table to answer the following problems. Construct the truth table as per the instructions in the textbook. Given the argument: K Q / Q K // K Q This argument is: the nurse is concerned that a patient they are treating may have psychological issues that could affect their care. which type of belief is the nurse expressing? awareness conviction experience stereotyping an inward shift in the u.s. economy's production possibility frontier could represent which? because verbal and telephone physician orders are very susceptible to error, the joint commission developed the ___________ to help alleviate errors. How many more bushels did mr myers pick of golden delicious apples than of red delicious apples give a state diagram for a deterministic finite automaton that recognizes the following language over = {0, 1}: {w : w has an even number of occurrences of the substring 01 and w has an odd length} WINGSUIT A wingsuit flyer jumps off a tall cliff. He falls freely for a few seconds before deploying the wingsuit and -4.9x +420, where y is = slowing his descent. His height during the freefall can be modeled by the function y the height above the ground in meters and x is the time in seconds. After deploying the wingsuit, the flyer's height is given by the function y = 3x + 200. deploy the wingsuit? Wilma had a loss of consciousness. When she first started to recover, she experienced _____.a) increased connectivity between subcortical and cortical areasb) increased activity in the cortexc) increased connectivity between the thalamus and hypothalamusd) increased connectivity between the thalamus and basal ganglia Choose your best photograph focusing on Line. Tell why this photo focuses on line. Write about directional and implied line. Discuss dynamics based on where the line leads the viewer's eye. Write at least 3 sentences about line. how many times has rihanna performed at the super bowl Assume that a secure baseline operating system is planned for wide...Assume that a secure baseline operating system is planned for wide deployment in a large organization. However, the baseline configuration prevents a mission-critical application from working. Over 100 employees use the mission-critical application daily.The administrators researched the issue exhaustively and found no solution.Should the administrators weaken security by not using the baseline settings? Why or why?Is there another solution? Explain your answe structures atop the brain or a structure within the brain are_____: Kolbys Korndogs is looking at a new sausage system with an installed cost of $675,000. This cost will be depreciated straight-line to zero over the projects 5-year life, at the end of which the sausage system can be scrapped for $89,000. The sausage system will save the firm $191,000 per year in pretax operating costs, and the system requires an initial investment in net working capital of $43,000. If the tax rate is 24 percent and the discount rate is 8 percent, what is the NPV of this project? preparing effective speech intros what does your textbook say a hydraulic cylinder lifts a car (f2) delivering a force of 58000 n. the diameter of the small cylinder is 9 cm and the diameter of the large cylinder is 17 cm. find the necessary applied force (f1). 1. 8 L of a 2. 4M solution of NiCl2 is diluted to 4,5 L. What is the resulting concentration of the diluted solution? luca wants to insert a pivot table. he clicks on a single cell inside the data set, then proceeds to step x, and finally clicks ok in the dialog box that appears after step 2. what can step 2 be? Print the sum of all the elements contained in the double array named a. Use a counter-controlled loop. I've placed the definition of the array in a separate file. arrays.cpp 1 #include 2 #include 3 using namespace std; 4 5 #include "arrays.h" // a is defined here 6 7 int main() 8 { 9 int i=0; 10 auto LEN{sizeof(a)/sizeof(a[0])}; 11 double sum=0; 12 for(i;i what does it mean to apply an anthropological perspective to contemporary global issues?