Main.cc: In function 'int main()':
Main.cc:7:6: error: 'km' was not declared in this scope
km=d*6;
^
Main.cc:11:9: error: 'km' was not declared in this scope
km=2*6+(d-2)*1.8;
^
Main.cc:15:9: error: 'km' was not declared in this scope
km=km+1.8*1.5*(d-10);
^