c++ my boolean operator return only 0
#include <iostream>
#include<string>
using namespace std;
class Student{
public:
string name;
string major;
double gpa;
Student(string aName, string aMajor, double aGpa){
name=aName;
major=aMajor;
aGpa=gpa;
}
bool hasHonor(){
if (aGpa>=3.5)
return true;
if (aGpa<3.5)
return false;
}
};
int main()
{
Student student1("Jim", "Businnes", 2.4);
Student student2("Pam", "Art", 4);
cout<<student2.hasHonor()<<endl;
cout<<student1.hasHonor();
return 0;
}