I am just starting a programming class in C++ and my teacher hasn't taught anything about writing pseduocode and programs, yet expects us to be able to do so. I need help!!!!
1. Write out a complete algorithm in pseudocode for the following: User enters two uppercase letters or two lowercase letters. Design an algorithm that determines which letter lies halfway between any two letters of the alphabet and displays that letter.
~I thought that you would have to asign each letter of the alphabet a number, A=1, B=2... and use have the computer convert the letters into numbers, preform division, and convert back to a letter, but I don't know if that is even close to correct or not.
2. All years that are evenly divisible by 400 are always a leap year. A year is also a leap year if it is evenly divisible by 4 but not evenly divisible by 100. For example, 1600 was a leap year because it is evenly divisible by 400. 1988 was a leap year because it was evenly divisible by 4 AND not evenly divisible by 100. Design an algorithm that will determine if a year entered by the user is a leap year. The output should restate the input year and describe it as a leap year or not a leap year.
~I think I have to have a formula that is YearInput/400, if yes, state "Year is a leapyear". If it is not, have it calculate YearInput/4 evenly but not YearInput/100 not evenly, if yes state "Year is a leapyear." If not, state year and "Not leapyear." I don't know if this is anywhere close to correct.
3. Write out a complete algorithm for the following problem, and then use C++ syntax to create your first program. "The user should be requested to enter a number of seconds. The program should read int he user's number and conver the number of seconds entered by the user to the equivalent number of hours, minutes, and seconds and output this result."
~I really don't have very many ideas for this one. I think I will have to use a formula that will divide the number of seconds into hours, seconds into minutes, and the remainder will be seconds. I just don't know how to do it.
IF ANYONE CAN GIVE ME EVEN A LITTLE HELP THAT WOULD BE GREAT!!!!