可以自定義和繼承 /// <summary> /// 設計器支持所需的方法 - 不要 /// 使用代碼編輯器修改此方法的內(nèi)容。 /// </summary> private void InitializeComponent() { this.components = new System.ComponentModel.Container(); this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; this.Text = "Form1"; }
上傳時間: 2016-08-15
上傳用戶:baobao9437
/*import java.util.Scanner; //主類 public class student122 { //主方法 public static void main(String[] args){ //定義7個元素的字符數(shù)組 String[] st = new String[7]; inputSt(st); //調(diào)用輸入方法 calculateSt(st); //調(diào)用計算方法 outputSt(st); //調(diào)用輸出方法 } //其他方法 //輸入方法 private static void inputSt(String st[]){ System.out.println("輸入學生的信息:"); System.out.println("學號 姓名 成績1,2,3"); //創(chuàng)建鍵盤輸入類 Scanner ss = new Scanner(System.in); for(int i=0; i<5; i++){ st[i] = ss.next(); //鍵盤輸入1個字符串 } } //計算方法 private static void calculateSt(String[] st){ int sum = 0; //總分賦初值 int ave = 0; //平均分賦初值 for(int i=2;i<5;i++) { /計總分,字符變換成整數(shù)后進行計算 sum += Integer.parseInt(st[i]); } ave = sum/3; //計算平均分 //整數(shù)變換成字符后保存到數(shù)組里 st[5] = String.valueOf(sum); st[6] = String.valueOf(ave); } //輸出方法 private static void outputSt(String[] st){ System.out.print("學號 姓名 "); //不換行 System.out.print("成績1 成績2 成績3 "); System.out.println("總分 平均分");//換行 //輸出學生信息 for(int i=0; i<7; i++){ //按格式輸出,小于6個字符,補充空格 System.out.printf("%6s", st[i]); } System.out.println(); //輸出換行 } }*/ import java.util.Scanner; public class student122 { public static void main(String[] args) { // TODO 自動生成的方法存根 String[][] st = new String[3][8]; inputSt(st); calculateSt(st); outputSt(st); } //輸入方法 private static void inputSt(String st[][]) { System.out.println("輸入學生信息:"); System.out.println("班級 學號 姓名 成績:數(shù)學 物理 化學"); //創(chuàng)建鍵盤輸入類 Scanner ss = new Scanner(System.in); for(int j = 0; j < 3; j++) { for(int i = 0; i < 6; i++) { st[j][i] = ss.next(); } } } //輸出方法 private static void outputSt(String st[][]) { System.out.println("序號 班級 學號 姓名 成績:數(shù)學 物理 化學 總分 平均分"); //輸出學生信息 for(int j = 0; j < 3; j++) { System.out.print(j+1 + ":"); for(int i = 0; i < 8; i++) { System.out.printf("%6s", st[j][i]); } System.out.println(); } } //計算方法 private static void calculateSt(String[][] st) { int sum1 = 0; int sum2 = 0; int sum3 = 0; int ave1 = 0; int ave2 = 0; int ave3 = 0; for(int i = 3; i < 6; i++) { sum1 += Integer.parseInt(st[0][i]); } ave1 = sum1/3; for(int i = 3; i < 6; i++) { sum2 += Integer.parseInt(st[1][i]); } ave2 = sum2/3; for(int i = 3; i < 6; i++) { sum3 += Integer.parseInt(st[2][i]); } ave3 = sum3/3; st[0][6] = String.valueOf(sum1); st[1][6] = String.valueOf(sum2); st[2][6] = String.valueOf(sum3); st[0][7] = String.valueOf(ave1); st[1][7] = String.valueOf(ave2); st[2][7] = String.valueOf(ave3); } }
標簽: java 數(shù)據(jù)庫
上傳時間: 2017-03-17
上傳用戶:simple
#include "iostream" using namespace std; class Matrix { private: double** A; //矩陣A double *b; //向量b public: int size; Matrix(int ); ~Matrix(); friend double* Dooli(Matrix& ); void Input(); void Disp(); }; Matrix::Matrix(int x) { size=x; //為向量b分配空間并初始化為0 b=new double [x]; for(int j=0;j<x;j++) b[j]=0; //為向量A分配空間并初始化為0 A=new double* [x]; for(int i=0;i<x;i++) A[i]=new double [x]; for(int m=0;m<x;m++) for(int n=0;n<x;n++) A[m][n]=0; } Matrix::~Matrix() { cout<<"正在析構中~~~~"<<endl; delete b; for(int i=0;i<size;i++) delete A[i]; delete A; } void Matrix::Disp() { for(int i=0;i<size;i++) { for(int j=0;j<size;j++) cout<<A[i][j]<<" "; cout<<endl; } } void Matrix::Input() { cout<<"請輸入A:"<<endl; for(int i=0;i<size;i++) for(int j=0;j<size;j++){ cout<<"第"<<i+1<<"行"<<"第"<<j+1<<"列:"<<endl; cin>>A[i][j]; } cout<<"請輸入b:"<<endl; for(int j=0;j<size;j++){ cout<<"第"<<j+1<<"個:"<<endl; cin>>b[j]; } } double* Dooli(Matrix& A) { double *Xn=new double [A.size]; Matrix L(A.size),U(A.size); //分別求得U,L的第一行與第一列 for(int i=0;i<A.size;i++) U.A[0][i]=A.A[0][i]; for(int j=1;j<A.size;j++) L.A[j][0]=A.A[j][0]/U.A[0][0]; //分別求得U,L的第r行,第r列 double temp1=0,temp2=0; for(int r=1;r<A.size;r++){ //U for(int i=r;i<A.size;i++){ for(int k=0;k<r-1;k++) temp1=temp1+L.A[r][k]*U.A[k][i]; U.A[r][i]=A.A[r][i]-temp1; } //L for(int i=r+1;i<A.size;i++){ for(int k=0;k<r-1;k++) temp2=temp2+L.A[i][k]*U.A[k][r]; L.A[i][r]=(A.A[i][r]-temp2)/U.A[r][r]; } } cout<<"計算U得:"<<endl; U.Disp(); cout<<"計算L的:"<<endl; L.Disp(); double *Y=new double [A.size]; Y[0]=A.b[0]; for(int i=1;i<A.size;i++ ){ double temp3=0; for(int k=0;k<i-1;k++) temp3=temp3+L.A[i][k]*Y[k]; Y[i]=A.b[i]-temp3; } Xn[A.size-1]=Y[A.size-1]/U.A[A.size-1][A.size-1]; for(int i=A.size-1;i>=0;i--){ double temp4=0; for(int k=i+1;k<A.size;k++) temp4=temp4+U.A[i][k]*Xn[k]; Xn[i]=(Y[i]-temp4)/U.A[i][i]; } return Xn; } int main() { Matrix B(4); B.Input(); double *X; X=Dooli(B); cout<<"~~~~解得:"<<endl; for(int i=0;i<B.size;i++) cout<<"X["<<i<<"]:"<<X[i]<<" "; cout<<endl<<"呵呵呵呵呵"; return 0; }
標簽: 道理特分解法
上傳時間: 2018-05-20
上傳用戶:Aa123456789
For nearly a hundred years telecommunications provided mainly voice services and very low speed data (telegraph and telex). With the advent of the Internet, several data services became mainstream in telecommunications; to the point that voice is becoming an accessory to IP-centric data networks. Today, high-speed data services are already part of our daily lives at work and at home (web surfing, e-mail, virtual private networks, VoIP, virtual meetings, chats...). The demand for high-speed data services will grow even more with the increasing number of people telecommuting.
上傳時間: 2020-05-27
上傳用戶:shancjb
The ever-increasing demand for private and sensitive data transmission over wireless net- works has made security a crucial concern in the current and future large-scale, dynamic, and heterogeneous wireless communication systems. To address this challenge, computer scientists and engineers have tried hard to continuously come up with improved crypto- graphic algorithms. But typically we do not need to wait too long to find an efficient way to crack these algorithms. With the rapid progress of computational devices, the current cryptographic methods are already becoming more unreliable. In recent years, wireless re- searchers have sought a new security paradigm termed physical layer security. Unlike the traditional cryptographic approach which ignores the effect of the wireless medium, physi- cal layer security exploits the important characteristics of wireless channel, such as fading, interference, and noise, for improving the communication security against eavesdropping attacks. This new security paradigm is expected to complement and significantly increase the overall communication security of future wireless networks.
標簽: Communications Physical Security Wireless Layer in
上傳時間: 2020-05-31
上傳用戶:shancjb
Changes in telecommunications are impacting all types of user group, which include business users, traveling users, small and home offices, and residential users. The acceptance rate of telecom- munications and information services is accelerating significantly. Voice services needed approximately 50 years to reach a very high teledensity; television needed just 15 years to change the culture and lives of many families; the Internet and its related services have been penetrating and changing business practices and private com- munications over the last 2 to 3 years.
標簽: Telecommunications Handbook The
上傳時間: 2020-06-01
上傳用戶:shancjb
c++為我們所提供的各種存取控制僅僅是在編譯階段給我們的限制,也就是說是編譯器確保了你在完成任務之前的正確行為,如果你的行為不正確,那么你休想構造出任何可執(zhí)行程序來。H如果真正到了產(chǎn)生可執(zhí)行代碼階段,無論是c,ct+,還是pascal,大家都一樣,你認為c和C++編譯器產(chǎn)生的機器代碼會有所不同嗎,你認為c++產(chǎn)生的機器代碼會有訪問限制嗎?那么你錯了。什么const,private,統(tǒng)統(tǒng)沒有(const變量或許會放入只讀數(shù)據(jù)段),它不會再給你任何的限制,你可以利用一切內(nèi)存修改工具或者是自己寫一個程序?qū)δ骋贿M程空間的某一變量進行修改,不管它在你的印象中是private,還是public,對于此時的你來說都一樣,想怎樣便怎樣.另外,你也不要為c++所提供的什么晚期捆綁等機制大呼神奇,它也僅僅是在所產(chǎn)生的代碼中多加了幾條而已,它遠沒有你想象的那么智能,所有的工作都是編譯器幫你完成,真正到了執(zhí)行的時候,計算機會完全按照編譯器產(chǎn)生的代碼一絲不茍的執(zhí)行。(以下的反匯編代碼均來自visial c++ 7.0)一.讓我們從變量開始--并非你想象的那么簡單
標簽: C++
上傳時間: 2022-06-27
上傳用戶:1208020161