1 / 7

COMP2012H: OOP and DS (honors track) course.cst.hk/comp2012h

COMP2012H: OOP and DS (honors track) http://course.cs.ust.hk/comp2012h. Fast-paced High workload Learn many details on your own Therefore, you must be both good and hard-working to succeed COMP2012H challenges the best and the most independently minded!. Announcement. No lab in week 1

Download Presentation

COMP2012H: OOP and DS (honors track) course.cst.hk/comp2012h

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. COMP2012H: OOP and DS (honors track) http://course.cs.ust.hk/comp2012h Fast-paced High workload Learn many details on your own Therefore, you must be both good and hard-working to succeed COMP2012H challenges the best and the most independently minded!

  2. Announcement • No lab in week 1 • Want to skip all the labs: score them all before Mar 4! See courseweb for details.

  3. Hello World! #include <iostream.h> using namespace std; int main() { cout << "hello, world!" << endl; return 0; } contains classes/objects useful for screen output e.g. cout

  4. org 100h ; set video mode mov ax, 3 ; text mode 80x25, 16 colors, 8 pages (ah=0, al=3) int 10h ; do it! ; cancel blinking and enable all 16 colors: mov ax, 1003h mov bx, 0 int 10h ; set segment register: mov ax, 0b800h mov ds, ax ; print "hello world" ; first byte is ascii code, second byte is color code. mov [02h], 'h' mov [04h], 'e' mov [06h], 'l' mov [08h], 'l' mov [0ah], 'o' mov [0ch], ',' mov [0eh], 'w' mov [10h], 'o' mov [12h], 'r' mov [14h], 'l' mov [16h], 'd' mov [18h], '!' ; color all characters: mov cx, 12 ; number of characters. mov di, 03h ; start from byte after 'h' c: mov [di], 11101100b ; light red(1100) on yellow(1110) add di, 2 ; skip over next ascii code in vga memory. loop c ; wait for any key press: mov ah, 0 int 16h ret Who wants to write this … except COMP180 students ?!

  5. What’s good about OOP? • Objects separate interface from implementation • In C++, interface is given by .h files, and implementation by .cpp files

  6. Suggested Work Schedule for Project #1 • Due on Mar 8! • (14 days) work up to lab5. • Learn QT / some inheritance on your own • (14 days) work on project #1. • OOP allows you to implement the requirements readily by using QT classes • (4 days) backup • in case you fall short of the above schedule

  7. Due dates and late penalty • Projects are due at 23:59:00 on the due date. You are permitted a total of five late days without penalty for the semester that may be used on any of the five programming projects. • See courseweb for details (or ask questions now!)

More Related