Write program to enter name-number of planet from sun

Assignment Help Programming Languages
Reference no: EM1382161

Write down the program which permits the user to enter name of planet, and then prints message stating that planet's number when counted outward from sun. If user enters datum which is not a planet, your program must print message to that effect.

You will probably wish to start your program by declaring array of string literals, given below. You can then refer to name of planet i with planets[i].

char* planets[8] = {"Mercury", "Venus", "Earth", "Mars", "Jupiter", "Saturn", "Uranus", "Neptune"};

Example run might look like following:

Enter planet name: Earth
Earth is planet 3, counting outward from the Sun.

Reference no: EM1382161

Questions Cloud

Charactristics of the atomic structure of helium : In modern blimps, the gas of choice used to inflate them is helium rather than hydrogen. Hydrogen would be lighter, but helium is safer. Compare and contrast the atomic structure of hydrogen and helium.
What is your business are being sued for a breach : What is your business are being sued for a breach of contract. Create a matrix that list each business and compare and contrast your personal liability exposure as a sole owner as a result of the lawsuit.
Factor label method to calculate number of grams of kmno4 : Discuss how do use the factor-label method to calculate the number of grams of KMnO4 that you would need to make 100 ml of a 0.0045 M potassium permanganate solution?
Many students of the second city training center : Many students of the Second City Training Center arebusinesspeople looking to gain skills for the corporatecontext. What skills from the world of improvisationalcomedy would be valuable to a business manager?
Write program to enter name-number of planet from sun : Write down the program which permits the user to enter name of planet, and then prints message stating that planet's number when counted outward from sun.
Design project : Specify a fire wall of appropriate resistance which utilizes masonry. Provide a construction detail of how it is to be constructed. Please note this is a load bearing wall - FSE 445 Design Project
Reality of the current organizational situation : According to Senge, leaders must understand this notion, which represents the difference between the "vision" of where the organization could be and the reality of the current organizational situation.
Abc airlines has calculated the total costs : ABC Airlines has calculated the total costs (fixed and variable) for the passenger service flights between Los Angeles, California and Orlando, Florida.
The firm is opening its headquarters in chicago : The firm is opening its headquarters in Chicago and is considering three office locations, which differ in cost due to square footage and office equipment requirements

Reviews

Write a Review

Programming Languages Questions & Answers

  Find largest number in array

Find the largest number in the array and output the result. use a subprogram to input the numbers, a function to use the largest number.

  Design a website to allow calculation of areas

Design a website to permit calculation of areas. A radio button list can be used to allow the user select what type of area to be calculated. Once the selection is done, the input text boxes should be displayed with the proper labels.

  Write function which take parameter-string and returns vowel

Write function which takes as parameter and string and returns the vowels (a, e, i, o, u). Function prototype should look like: void countVowels(string str, int& aCt, int& eCt, int& iCt, int& oCt, int& uCt);

  Write stored function that takes in zipcode as parameters

Write a stored function called zip_exist that takes in a zipcode.zip%Type parameter and returns a Boolean. The function will return TRUE if the zipcode passed into it exists.

  Create class using static variable to store annual interest

Create class SavingAccount. Use a static variable annualInterestRate to store the annual interest rate for all account holders. Each object of the class contains a private instance variable savingsBalance indicating the amount.

  Program for insertion sort and selection sort algorithms

Write a program involving the insertion sort, merge sort and selection sort algorithms.

  Write program to calculate distance and time hurricane take

Write C++ program that will calculate the distance and time it will take (days/hours) for hurricane to reach Ft. Lauderdale if: Hurricane is at coordinates 16 N, 64 W, just SE of South Fla. off in Atlantic, with a speed of 20 mph.

  Program to continuously accepts each worker-s first name

Program which continuously accepts each worker's first and last names, this year's number of units produced, and last year's number of units produced.

  Create set-list of enumerated constants called week

Create set/list of enumerated constants called week which contains days of week. Have variable called today that is of kind week. Allot a value to today.

  Write a program to read student data from standard input

Write a program to read student data from standard input, sort it by last name / first name, and print result to standard output.

  Write the program by declaring one-dimensional array

Write the program by declaring one-dimensional array which could be used to hold data for grades (int type) of 10 students. The program will prompt user for numeric grades.

  Create command line based application for perfect hundred

Create a COMMAND LINE based application to play a game called Perfect Hundred. In this game, the user/player competes against the computer.

Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd