#include < iostream. h > class test{ private: int x;y; public: voicl f( int a,int b) { x = a;y = b; } int max( ) { return(x > y) ? x:y; } }; main( ) { test a; a. f( 1 ,3) ; cout << a. max( ) <&
#include < iostream > using namespace std; class base { private: int x; public: void setx (int a){x=a;} int getx ( ){return x;} } ; void main ( ) { base a,b; a.setx (89); b=a; cout
#include < iostream. h > void main( ){ float * p; p = new float[ 5 ] ; for( i =0;i <5 ;i + + ) { cin > > * (p + i) ;cout << * (p + i) << endl; } delete [ ] p; }
#include<iostream> using namespace std; class base { private: int x,y; public: void initxy(int a,int b){x=a;y=b;} void show() {______________} } ; void main() { base a,b; _____________
#include <iostream> using namespace std; class A { private: int a;int b; public: _________________{ a = x;b = y; } void set(int x,int y) { a = x;b = y; } void display( ){ cout<<a<&l
#include <iostream.h> #include <string.h> class A{ public: virtual void GetA( ) = 0; }; class B:public A{ private: char str[32]; public: void GetA( ){ cout<<″Class A″<<endl; }
#include<iostream.h> #define PI 3.14;void main() { double i; int r; cout<<″输入圆形半径:″; cin>>r; i=2 * PI * r; cout<<″圆形周长=″<<i<<endl; i=PI * r * r; cout<<″圆形面积=″<
补全代码使程序输出的结果为两个数的商(如果除数为0,则输出错误信息提示“ERROR!”)。