Answer:
Explanation:
#include <stdio.h>
int main(void)
{
int num, rem;
printf("Enter a number: ");
scanf("%d", &num);
printf("Roman numerals: ");
while(num != 0)
{
if (num >= 1000) // 1000 - m
{
printf("m");
num -= 1000;
}
else if (num >= 900) // 900 - cm
{
printf("cm");
num -= 900;
}
else if (num >= 500) // 500 - d
{
printf("d");
num -= 500;
}
else if (num >= 400) // 400 - cd
{
printf("cd");
num -= 400;
}
else if (num >= 100) // 100 - c
{
printf("c");
num -= 100;
}
else if (num >= 90) // 90 - xc
{
printf("xc");
num -= 90;
}
else if (num >= 50) // 50 - l
{
printf("l");
num -= 50;
}
else if (num >= 40) // 40 - xl
{
printf("xl");
num -= 40;
}
else if (num >= 10) // 10 - x
{
printf("x");
num -= 10;
}
else if (num >= 9) // 9 - ix
{
printf("ix");
num -= 9;
}
else if (num >= 5) // 5 - v
{
printf("v");
num -= 5;
}
else if (num >= 4) // 4 - iv
{
printf("iv");
num -= 4;
}
else if (num >= 1) // 1 - i
{
printf("i");
num -= 1;
}
}
return 0;
}
Answer:
The method written in Java is as follows:
public static ArrayList<Double> removeHighPrice (ArrayList<Double> prices){
for(int i =0;i<prices.size();i++){
if(prices.get(i) > 5.00){
prices.remove(i);
break;
}
}
return(prices);
}
Explanation:
This line declares the method
public static ArrayList<Double> removeHighPrice (ArrayList<Double> prices){
This line iterates through the ArrayList named prices
for(int i =0;i<prices.size();i++){
This checks if current price is greater than 5
if(prices.get(i) > 5.00){
If yes, the price is removed
prices.remove(i);
And the loop is terminated
break;
}
}
This returns the ArrayList
return(prices);
}
<em>I've added as an attachment, the complete program which includes the main method</em>
<span>D. Page Layout i hope this helps </span>
A folder can include everything from documents and music, to applications [like Word or Excel or your favorite browser]. But computer folders can also contain other folders, lots of them, and those sub-folders can contain folders of their own. This is the called folder tree. The trunk of the tree is the Desktop. Then there are several folders like Recycle Bin, Control Panel,..The most important branch is the
one called ‘Libraries’. Here are the Photos, Music, Videos,...
<span>Using a windows computer, to expand a branch of the folder tree you would right click </span>beside various folders and drives to expand the folder tree.
The answer is the first response, by order of elimination, you can eliminate the rest.
HTML is a programming language that is used to design websites. You don't need to program a website to make a post on instagram, especially if you are using the app.
If you check the app store on your phone, you can find instagram in the app store, which lets you access it from your mobile device. Thus, the third option is wrong.
Finally, just read the description of instagram. It was made for sharing pictures, so the last option is wrong.