I resolved the question I was going to ask as I was typing out my question, hopefully, it'll happen again!
I'm creating a login system for practice, no encryption or anything, for calling classes from my main function. My issue is that I don't get any errors and yet the only text that appears is, "Login Practice System."
It almost seems that the function from the username class doesn't even run. Help? Thank you!
main.cpp
1 2 3 4 5 6 7 8 9 10 11 12
#include <iostream>
#include "username.h"
usingnamespace std;
int main()
{
cout << "Login Practice System \n";
Username uname;
return 0;
}
First: C++ is case sensitive. You have a class username, so you cannot use it as Username.
Second: In username.h: uname() is not the constructor (the name needs to be the class name). The compiler should give an error since that function does not have a return type.