有如下类和对象的定义: class Constants{ public: static double getPI( ){return 3.1416;} }; Constants constants; 下列各组语句中,能输出3.1416的是
A.
cout<<constants->getPI( );和cout<<Constants::getPI( );
B.
cout<<constants.getPI( );和cout<<Constants.getPI( );
C.
cout<<constants->getPI( );和cout<<Constants->getPI( )
D.
cout<<eonstants.getPI( );和cout<<Constants::getPI( );