• 暑期——第九周总结(1,林子雨老师关于hdfs eclipse案例报错问题【已解决】)


    所花时间:7天

    代码行:1000(Java)+500(Python)+300(C++)

    博客量:1篇

    了解到知识点 :

    一:

    解决"Class org.apache.hadoop.hdfs.DistributedFileSystem not found"问题

    hadoop-hdfs-client-3.1.1.jar

    1)”/usr/local/hadoop/share/hadoop/common”目录下的hadoop-common-2.7.1.jar和haoop-nfs-2.7.1.jar;
    2)/usr/local/hadoop/share/hadoop/common/lib”目录下的所有JAR包;
    3)“/usr/local/hadoop/share/hadoop/hdfs”目录下的haoop-hdfs-2.7.1.jar和haoop-hdfs-nfs-2.7.1.jar;hadoop-hdfs-client-3.1.1.jar
    4)“/usr/local/hadoop/share/hadoop/hdfs/lib”目录下的所有JAR包。

    二:

    C++ 字母转ASCII值

    intak;
        charch;
        ch='a';
        ak=ch;
        cout<<ak<<endl;

    C++ 查找替换字串:

    int main() {
        string s = "12+13";
        // 查找
        int index = s.find("+");
        // 替换, (起始位置, 子串长度, 替换后的值,这里替换为空,相当于删除)
        string ss = s.replace(index, 1, "");
        // 子串
        string sub = s.substr(0, index);
        return 0;
    }

    gets()与scanf()的区别

    gets()函数用来从标准输入设备(键盘)读取字符串直到回车结束, 但回车符

    不属于这个字符串。其调用格式为:

    gets(s);

           其中s为字符串变量(字符串数组名或字符串指针)。

           gets(s)函数与scanf("%s", s)相似, 但不完全相同, 使用scanf("%s", s)

    函数输入字符串时存在一个问题, 就是如果输入了空格会认为输入字符串结束,

    空格后的字符将作为下一个输入项处理, 但gets() 函数将接收输入的整个字符

    串直到回车为止。

    , , 的区别

    例如, 假设x一个实数型变量,则语句 
    printf(“%d
    ”, x); 
    输出x的当前值,然后把光标移到行首。 
    printf(“%d, x); 
    先输出x的当前值,然后再将其消掉,就像我们打字时 
    按退格键一样。 
    真正常用的转义符是
    (newline换行) 
    printf(“%d
    ”, x); 
    输出x的当前值,然后换行到下一行的行首
  • 相关阅读:
    your account already has a valid ios distribution certificate
    uinavigation样式
    phonegap ios默认启动页
    git init出错
    ios assetlibrary
    uitableviewcell高度自适应笔记
    ios frame bounds applicationframe
    java学习笔记
    file not found while xcode archive
    c++回调
  • 原文地址:https://www.cnblogs.com/smartisn/p/11439710.html
Copyright © 2020-2023  润新知