01 2022 档案
摘要:import numpy as np import xlrd read=xlrd.open_workbook('Z:\math\data.xlsx') sheet1=read.sheet_by_index(0) row=sheet1.nrows col=sheet1.ncols matrix=np.
阅读全文
摘要:1.构造评分公式 2.归一化 xi'=xi/∑x 3.统一指标类型 4.矩阵标准化 5.计算得分
阅读全文
摘要:1. 单行注释 % 这是注释 2. %%+程序块 那么再遇到下一个%%之前,这个部分将会作为一个程序块,这样在阅读程序的时候,会用黄白颜色进行间隔,方便阅读和浏览。 3.多行注释 %{ 注释 注释 注释 %}
阅读全文
摘要:1.cin>> string s; cin>>s; 读取 且 忽略 开头 所有的 空白字符 (空格,换行符,制表符\t 即按键盘上TAB) 读取,直至再次遇到空白符,终止 2.getline() string line; getline(cin,line); 不读取换行符 读取开头的空格 若第一个字
阅读全文
摘要:1.每次读入一个单词 #include<iostream> #include<string> using namespace std; int main(){ string word; int n=1; while(cin>>word){ cout<<n<<": "<<word<<endl; n++
阅读全文
摘要:1.字符 string str = “hello, world”; for(auto ch : str) { cout << ch << endl; } 2.
阅读全文
摘要:Windows control+z Unix || Macos control+d
阅读全文