Académique Documents
Professionnel Documents
Culture Documents
http://www.cse.msu.edu/facility/access/firstlogin.php
Every CSE student needs to complete the first login process. CSE uses the same username as your MSU NetID. Your initial password is your student PID, starting with capital A. Since new accounts use your student PID for a password, accounts are vulnerable until this process is completed. At any point you may receive an email reminding you of this. Procedure: In the Windows Lab, login to the CSE domain. Cltr-Alt-Delete and choose Change Password. CSE requires a strong password. Your new password must have the following characteristics: Be at least 7 characters long. Contain at least 4 different characters. Contain at least 2 characters which are not lowercase letters. Contain at least 2 characters which are not uppercase letters. Contain at least 2 characters which are not numerals. Contain at least 1 alphanumeric character. Not have a middle of all lowercase, uppercase, or numeric characters. Password examples: Bad passwords: secret, aSECRET9, $owndpsuF, a123456b, only1one Good passwords: 3bar4goo, AnYth1nG, only1onE Change your password now. Log back in with your new password, open an internet browser, and continue with the rest of the lab listed at:
http://www.cse.msu.edu/~cse232/Labs/lab01.dir
Left click on any of these things, see what happens. You are going to get very cozy with this environment, it is a good time to get used to it.
Start Terminal
From the Places menu you can see your home folder, the desktop, and other file areas. If you open the home folder, you get the screen on the right above. Double clicking on the Desktop icon opens the contents of that folder.
Having opened the Home folder, we see another folder, the Desktop. If we click on it we see the contents of the Desktop. We can move back and forth between the two folders using the navigation bar above the icons. If you select the View menu option, you can change how the browser works. In particular view hidden files in your hom folder. Lots of stuff there. During each lab, you will be required to show your Lab TA some results. By showing those results you get credit for attending the lab. These results will be clearly marked with a
! Please show your TA you can open a Terminal and File Browser.
Section 3.5 Netbeans IDE
Though you can (and eventually will) use the Terminal and a simple editor to write you code, it is useful to have a Integrated Development Environment (IDE) to help you. We are using netbeans, a Java environment that also works with C++. Start it now.
!.
Now that we have netbeans started, we will be working with the commands at the top of the netbeans application. Lets make a new project. Do File ! New Project. You will then go through the process of creating a new project as shown in the screens below. First select the type of project. We want a C++ project and as a C++ project we want a C++ application. Click on next and you get the next screen. You can accept all the
defaults here, but change the name (highlighted in blue) to proj01. Also change the main file name to proj01
See the tabs at the bottom of the project: Compile, Build-run, run. You can open these at any time to see the results of that operation. There is a tradition in computer science. The first program you run in a new language is the Hello World program. This program does nothing put print the words Hello World. It is a tradition because it does very little except focus on the mechanics of writing your first program and running it. Look at the wikibooks page http://en.wikibooks.org/wiki/List_of_hello_world_programs for more than 200 programming language examples of hello world In C++ Hello World is fairly easy. Two steps: under the line #include <stdlib> add the line #include<iostream> above the line return 0; o add the line cout << "Hello World" << endl; Do it exactly. Notice the # signs and the ; in particular. Compile and run it.
In the images above, the sidebars have been shrunk and are on the left side. There is a little window icon left of "start page" that controls this.
It should compile, and the output of the run should say Hello World.
Test your ability to run handin now. We will hand-in our proj01.cpp program as a solution to Project01 directory. Remember, you can hand-in as many times as you like, only the last one counts. So even though proj01.cpp doesnt solve the Project01 problem, it allows us to test that we can hand a program in. When we hand-in the real program, the old proj01.cpp will be overwritten. Where is the proj01.cpp file? You can use your file browser to find it. In Home ! NetBeansProjects!proj01 is the file proj01.cpp. This is the file to handin
If you have trouble, check with your TA now. Better now than just before the project is due.