Other articles


  1. C++-Notes

    程序的输出结果是

    #include<iostream>
    using namespace std;
    #define DOUBLE(x) x+x//x*2
    int main(int argc,char** argv)
    {
        int i=DOUBLE(5)*5;
        cout<<i<<endl;
        return 0;
    }
    

    输出结果是:30

    程序出错在什么阶段?()

    A、编译阶段出错 B、运行阶段出错 C、编译和运行都出错 D、程序运行正常

    #include<iostream>
    using namespace std;
    int main() 
    { 
    http://www.sogou …
    read more
  2. Java-Notes

    下列程序的输出结果是:

    public class test
    {
        public static void main(String args[])
        {
            String a="abc";
            String b="abc";
            String c=new String(b);
    
            System.out.print(a==b);/* a和b指向同一个对象**/
            System.out.print(' ');
            System.out.print(a==c);
            System.out.print(' ');
            System.out.print(c==b);
            System.out.println();
        }
    }
    

    结果是:true false false …

    read more

links

social