So this:
#include <iostream>
#include <cmath>
#include <cstdlib>
using namespace std;
int main()
{
double d = (1/6);
cout<<d;
return 0;
}
returns d as int, the fractional part is removed, can someone tell me why?