ok, so i have to write a program that takes in the current date and the date of the expiration of a food product in the form of mm/dd/yyyy
then i have to make 3 bool functions that do no input from the keyboard nor output to the screen. they do only logic.
those three bool functions are 'isvalid' which is true if the date is a valid date and false if otherwise. the other bool function is 'thesame' which is true if the two dates are the same and false otherwise. and the last bool function is called 'earlier' which is true if the 1st date (the expiration date) is earlier than the 2nd date (the current date)
i already made the functions, but then at the end of the program, i have to have the program either say 'the dates are the same', 'expiration date/current date is not valid', 'the expiration date is earlier than today', or 'the expiration date is later than today'
but i have no idea how to make my program put those outputs out. i have to use 'if' statements, please help!
2007-03-20
12:54:25
·
2 answers
·
asked by
63godtoh
3
in
Computers & Internet
➔ Programming & Design
icnintel, i havent the slightest clue of what your talking about
please, if you can, better yet if you get this message, can you explain it a little better than that?
i am in computer science 115, this is an intro to C++, i dont know much, only very very basic, and only some of that
i have to use 'if' statements to put those outputs i said at the end of my question from before
i dont know what ofstream is or how to get a text file or whatever that was, and we cant use what we havent been taught, and we havent been taught that stuff, so i can't use it, even if it works
please, if you can think of some way of using 'if' statements to get those outputs i want or some other easier way than that i would be very thankful
2007-03-20
13:35:00 ·
update #1
coosa, idk if you got the point i was trying to get across the last time you answered one of my questions, but nothing you are saying is of any use to me because i can not use anything your talking about
i am in a class, and our teacher does not want us using anything that we have not gone over in class. and, again, the things you are saying all are of no use to me
i cant use tokenizing, vectors or arrays, so everything your saying is not helping. please stop going on and leaving more messages for me when i cant understand or use any of it. there really is no point in it really
so please, unless you know how i can make an output to read a sentence that i make up like 'the dates are the same' based on three different BOOL functions i have, THAT I MUST KEEP AND CAN NOT CHANGE (and these bool functions only return true or false, nothing else), then dont carry on with a bunch of other stuff that i can not use, it really is just wasting your time and mine.
2007-03-20
14:21:04 ·
update #2
icnintel, thank you, your the only person on this site that has so far found a way to correctly answer one of my questions the way i needed it to be answered
and sorry if i seemed like i was making it to hard, its just im sure there are like a million easier ways to do this but if i use something that we have not gone over in class, even if it works, she will count it wrong
and its been hard to get people to understand that i cant use a lot of different techniques and that i have to stay in C++
sorry if i seemed like an ***, i just get so mad on this site so easily because of no one ever giving a response i want
2007-03-20
14:45:36 ·
update #3