A careless user can enter a character instead of an int. The program must display a message to the user that the entry in 'invalid'.
@fifaham Жыл бұрын
Nice video, thank you Kevin.
@PortfolioCourses Жыл бұрын
You’re welcome! :-)
@fifaham Жыл бұрын
@@PortfolioCourses By the way Kevin, this is off the subject of this video and I dont expect an answer since it is off the subject, did it happen to have any idea if it is possible to embedd a C++ code inside C code? I have done it with Assemby where I was able to easily embedd Assembly code within C code, but I am not aware if we can do that with C embedding C++ inside it.
@PortfolioCourses Жыл бұрын
I missed this question before. That's a great question, but to be honest I don't know, I haven't done it. :-) It looks like it's possible though: www.oracle.com/technical-resources/articles/it-infrastructure/mixing-c-and-cplusplus.html
@tbeng12 Жыл бұрын
Thanks for the tutorial sir, I've always wondered which one is faster, the one in the video or using cout 0 ? "Positive" : ( num == 0 ? "Zero" : "Negative" ) )
@PortfolioCourses Жыл бұрын
I don't think there will be a big performance difference either way in practice, compilers can do all sorts of interesting things to optimize execution, but if I had to guess this version is likely to be faster. :-)