08 2023 档案
摘要:1. source 命令用于执行被修改的配置文件,使最新配置更新到操作系统 通常有如下命令 source ~/.profile source ~/.bash_profile source /etc/profile如果碰到sudo: source: command not found问题,主要是因为系
阅读全文
摘要:1. 将float型赋值给整型 比如float f=3.14int i=fi 最后等于3。 这个转换是由编译器完成的,当把float型的数据赋值给int型数据时,编译器会自动截断小数点后的数,把整数部分赋给int类型的变量 由此可推断出四舍五入的实现方法:int a = b+0.5; 2. for循
阅读全文