Answer:
They basiclly are used like a level up in other words they cause you to level up.
Explanation:
Want free points mark as brainiest
If i wanted to change my phones simcard, does anything need transferring, or is it an easy swap?
Complete a prewritten C++ program for a carpenter who creates personalized house signs. The program is supposed to compute the price of any sign a customer orders, based on the following facts:
The charge for all signs is a minimum of $35.00.
The first five letters or numbers are included in the minimum charge; there is a $4 charge for each additional character.
If the sign is made of oak, add $20.00. No charge is added for pine.
Black or white characters are included in the minimum charge; there is an additional $15 charge for gold-leaf lettering.
Instructions:
Ensure the file named HouseSign.cppis open in the code editor. You need to declare variables for the following, and initialize them where specified:
A variable for the cost of the sign initialized to 0.00 (charge).
A variable for the number of characters initialized to 8 (numChars).
A variable for the color of the characters initialized to "gold" (color).
A variable for the wood type initialized to "oak" (woodType).
Write the rest of the program using assignment statements and ifstatements as appropriate. The output statements are written for you.
Answer:
#include <iostream>
#include <string>
using namespace std;
int main()
{
double charge = 0.00;
int numChars = 8;
string color = "gold";
string woodType = "oak";
if(numChars > 5){
charge += (numChars - 5) * 4;
}
if(woodType == "oak"){
charge += 20;
}
if(color == "gold"){
charge += 15;
}
charge += 35;
cout << "The charge is: $" << charge << endl;
return 0;
}
Explanation:
Include the string library
Initialize the variables as specified
Check if the number of characters is greater than 5 or not. If it is, add 4 to the charge for each character that is greater than 5
Check if the sign is made of oak or not. If it is, add 20 to the charge
Check if the color is gold or not. If it is, add 35 to the charge
Add the minimum cost to the charge
Print the charge
In this exercise we have to use the knowledge of the C++ language to write the code, so we have to:
The code is in the attached photo.
So to make it easier the code can be found at:
#include <iostream>
#include <string>
using namespace std;
int main()
{
double charge = 0.00;
int numChars = 8;
string color = "gold";
string woodType = "oak";
if(numChars > 5){
charge += (numChars - 5) * 4;
}
if(woodType == "oak"){
charge += 20;
}
if(color == "gold"){
charge += 15;
}
charge += 35;
cout << "The charge is: $" << charge << endl;
return 0;
}
See more about C++ at brainly.com/question/26104476
(Convert milliseconds to hours, minutes, and seconds) Write a function that converts milliseconds to hours, minutes, and seconds using the following header: def convertMillis(millis): The function returns a string as hours:minutes:seconds. For example, convertMillis(5500) returns the string 0:0:5, convertMillis(100000) returns the string 0:1:40, and convertMillis(555550000) returns the string 154:19:10. Write a test program that prompts the user to enter a value for milliseconds and displays a string in the format of hours:minutes:seconds. Sample Run Enter time in milliseconds: 555550000 154:19:10
Answer:
I am writing the Python program. Let me know if you want the program in some other programming language.
def convertMillis(millis): #function to convert milliseconds to hrs,mins,secs
remaining = millis # stores the value of millis to convert
hrs = 3600000 # milliseconds in hour
mins = 60000 # milliseconds in a minute
secs = 1000 #milliseconds in a second
hours =remaining / hrs #value of millis input by user divided by 360000
remaining %= hrs #mod of remaining by 3600000
minutes = remaining / mins # the value of remaining divided by 60000
remaining %= mins #mod of remaining by 60000
seconds = remaining / secs
#the value left in remaining variable is divided by 1000
remaining %= secs #mod of remaining by 1000
print ("%d:%d:%d" % (hours, minutes, seconds))
#displays hours mins and seconds with colons in between
def main(): #main function to get input from user and call convertMillis() to #convert the input to hours minutes and seconds
millis=input("Enter time in milliseconds ") #prompts user to enter time
millis = int(millis) #converts user input value to integer
convertMillis(millis) #calls function to convert input to hrs mins secs
main() #calls main() function
Explanation:
The program is well explained in the comments mentioned with each line of code. The program has two functions convertMillis(millis) which converts an input value in milliseconds to hours, minutes and seconds using the formula given in the program, and main() function that takes input value from user and calls convertMillis(millis) for the conversion of that input. The program along with its output is attached in screenshot.