I GOT THIS very rush project , i nid to make a TIMEZONE converter program, it goes like this, u enter ur nations time. ex( philippines 9:00)< this must be constant. then the program converts the time and should display the different timezones of 10 different countries output: ex.( us:8;00 can: 8;30 ph 8;45 etc..) i have tried looping, but i just cant get right, i really nid ur suggestions.:freak:
hen the program converts the time and should display the"EQUIVALENT" different timezones of 10 different countries ^^
Take it step by step and make sure each bit works before moving onto the next bit. Don't attempt to write the whole program in one go. Get the input from the user and convert it however you want, then display what you think you've got. If that's correct then move onto the next bit: if it's a loop, forget the loop for now and just do it for one thing, so having got the data for PH then do the conversion for US and display the result, and make sure that is correct before moving on. Bear in mind that you will be implementing a loop at some point, so maybe make the code dependent on what will be a loop variable: Code: int i=0; i=5; // some code dependent on i, and eventually you will have: for (int i=0; i<10; i++) { // some code dependent on i } Then implement the loop. This bit should be fairly trivial once you've got the preceding steps worked out, and if I've read the problem description correctly then that should be it. When you get stuck post the complete code. It shouldn't be too long; I expect the whole of this program can be done in less than 50 lines of code. Make sure your code is indented correctly and uses sensible variable names, and use code blocks* to ensure the formatting is preserved. *which you know about, having read the posting guidelines, right?