Hello everyone, I'm working on debugging some code (this is a homework question, but I only want to be guided in the right direction) and I can't seem to figure out what I'm supposed to be doing, as there isn't much info to go on. Here's the original code.
// Debug 4-3
// Function displays course information
// instructor defaults to Staff
// enrollment defualts to 30
#include<iostream.h>
#include<conio.h>
I'm at a loss as to how the program is actually supposed to display the course information. All I have to go on are the comments at the top of the program. Any hints would be greatly appreciated.
consider 2 approaches
#1, comment out everything that doesn't work and add in one line at a time until you get a working code.
#2
Here is what I would do.
Forget about debugging this code for a minute. It's very small, so should take you no time to re-write. Think about getting the data from main() and passing it to this function. Use it as a guideline.