CS1101: Programming Methodology

Slides:



Advertisements
Similar presentations
Student Projects in the Course Data Structures
Advertisements

Problem Solving and Algorithm Design
Data Structures.
Ch:8 Design Concepts S.W Design should have following quality attribute: Functionality Usability Reliability Performance Supportability (extensibility,
Algorithms and Data Structures
Review. What to know You are responsible for all material covered in lecture, the readings, or the programming assignments There will also be some questions.
CMPT 225 Data Structures and Programming. Course information Lecturer: Jan Manuch (Jano), TASC TAs: Osama Saleh,
CSCE 210 Data Structures and Algorithms
DAST, Spring © L. Joskowicz 1 Data Structures – LECTURE 1 Introduction Motivation: algorithms and abstract data types Easy problems, hard problems.
General information CSE 230 : Introduction to Software Engineering
CMSC 132: Object-Oriented Programming II Nelson Padua-Perez William Pugh Department of Computer Science University of Maryland, College Park.
CS 206 Introduction to Computer Science II 04 / 29 / 2009 Instructor: Michael Eckmann.
CS 206 Introduction to Computer Science II 12 / 10 / 2008 Instructor: Michael Eckmann.
Chapter 1 Principles of Programming and Software Engineering.
Data Structures, Spring 2004 © L. Joskowicz 1 DAST – Final Lecture Summary and overview What we have learned. Why it is important. What next.
Data Structures Using C++1 Chapter 1 Software Engineering Principles and C++ Classes.
1 ES 314 Advanced Programming Lec 2 Sept 3 Goals: Complete the discussion of problem Review of C++ Object-oriented design Arrays and pointers.
© 2006 Pearson Addison-Wesley. All rights reserved2-1 Chapter 2 Principles of Programming & Software Engineering.
DAST, Spring © L. Joskowicz 1 Data Structures – LECTURE 1 Introduction Motivation: algorithms and abstract data types Easy problems, hard problems.
OBJECT ORIENTED PROGRAMMING IN C++ LECTURE
Data Structures and Programming.  John Edgar2.
Computer Science 102 Data Structures and Algorithms V Fall 2009 Lecture 1: administrative details Professor: Evan Korth New York University 1.
Teaching Teaching Discrete Mathematics and Algorithms & Data Structures Online G.MirkowskaPJIIT.
Dr. Ken Hoganson, © August 2014 Programming in R STAT8030 Programming in R COURSE NOTES 1: Hoganson Programming Languages.
GENERAL CONCEPTS OF OOPS INTRODUCTION With rapidly changing world and highly competitive and versatile nature of industry, the operations are becoming.
EECE 310 Software Engineering Lecture 0: Course Orientation.
CSC 354 – Software Engineering, Spring 2013, Week 2 Mythical Man-Month Ch. 1-5 Tar Pit, Mythical Man-Month, Surgical Team, Aristocracy / Democracy & System.
Processing & Java An Introduction to Computing. © Calvin College, Computer Science is no more about computers than astronomy is about telescopes.
CSCA48 Course Summary.
Introduction CS 3358 Data Structures. What is Computer Science? Computer Science is the study of algorithms, including their  Formal and mathematical.
Problem Solving and Algorithm Design. 2 Problem Solving Problem solving The act of finding a solution to a perplexing, distressing, vexing, or unsettled.
SOFTWARE DESIGN.
1 CSC 222: Computer Programming II Spring 2004 See online syllabus at: Course goals:
Computer Science 102 Data Structures and Algorithms CSCI-UA.0102 Fall 2012 Lecture 1: administrative details Professor: Evan Korth New York University.
June 05 David A. Gaitros Jean Muhammad Introduction to OOD and UML Dr. Jean Muhammad.
CMSC 2021 CMSC 202 Computer Science II for Majors Fall 2002 Mr. Frey (0101 – 0104) Mr. Raouf (0201 – 0204)
Introduction CS 3358 Data Structures. What is Computer Science? Computer Science is the study of algorithms, including their  Formal and mathematical.
Object-Oriented Analysis and Design Fall 2009.
1 CSC 222: Object-Oriented Programming Spring 2013 Course goals:  To know and use basic Java programming constructs for object- oriented problem solving.
Data Structures and Algorithms – using JAVA Boro Jakimovski University of Sts Cyril and Methodius, Skopje.
Data Structures Using C++1 Chapter 1 Software Engineering Principles and C++ Classes.
December 4, Algorithms and Data Structures Lecture XV Simonas Šaltenis Aalborg University
CompSci CompSci 6 Programming Design and Analysis I Dietolf (Dee) Ramm
The Programming Process Define the problem* Make or buy software? Design the program * Code (write) the program Test (debug) the program Document the.
CS1101: Programming Methodology
1 CSCD 326 Data Structures I Software Design. 2 The Software Life Cycle 1. Specification 2. Design 3. Risk Analysis 4. Verification 5. Coding 6. Testing.
Data Structures and Algorithm Analysis Introduction Lecturer: Ligang Dong, egan Tel: , Office: SIEE Building.
Software Design 14.1 CPS 108 l Object oriented design and programming of medium-sized projects in groups using modern tools and practices in meaningful.
Data Structures Using C++ 2E
© 2006 Pearson Addison-Wesley. All rights reserved2-1 Chapter 2 Principles of Programming & Software Engineering.
There are only 10 different kinds of people in the world: those who know binary and those who don't. - Anonymous.
© 2006 Pearson Addison-Wesley. All rights reserved 2-1 Chapter 2 Principles of Programming & Software Engineering.
CMSC 2021 CMSC 202 Computer Science II for Majors Spring 2002 Sections Ms. Susan Mitchell.
CMSC 2021 CMSC 202 Computer Science II for Majors Spring 2001 Sections Ms. Susan Mitchell.
Data Structure Introduction Dr. Bernard Chen Ph.D. University of Central Arkansas Fall 2010.
CSI 1340 Introduction to Computer Science II Chapter 1 Software Engineering Principles.
CMSC 2021 CMSC 202 Computer Science II for Majors Spring 2003 Mr. Frey (0101 – 0104) Mr. Raouf (0201 – 0204)
Data Structures and Algorithms in Java AlaaEddin 2012.
1 CS 132 Spring 2008 Chapter 1 Software Engineering Principles and C++ Classes.
Naija Dukes 2011 Nigeria JUG, Lagos Demystifying Programming. Akintayo A. Olusegun, +trinisoftinc,
Principles of Programming & Software Engineering
CSCE 210 Data Structures and Algorithms
CSC 222: Computer Programming II
CSc 020: Programming Concepts and Methodology II
DDC 2423 DATA STRUCTURE Main text:
Midterm Review.
CSC 222: Object-Oriented Programming
EECE 310 Software Engineering
Review CSE116 2/21/2019 B.Ramamurthy.
Final Review B.Ramamurthy 5/8/2019 BR.
Presentation transcript:

CS1101: Programming Methodology

Week 13  Previous lecture:  Recursion (non-examinable)  This week:  Wrapping up  Past year’s paper © CS1101 (AY Semester 1)Week13 - 2

Wrapping Up Programming methodology Abstraction CS1102 Data Structures and Algorithms CS2103 Software Engineering/CS2261 Entreprise Systems Development The Joys of the Craft © CS1101 (AY Semester 1)Week13 - 3

Programming Methodology How do we begin writing a program? What are the style/design principles? © CS1101 (AY Semester 1)Week

Procedural Abstraction Break a problem into subproblems.  Break each subproblem into sub-subproblems.  Simplify until the subproblem is easily solvable. Write a procedure (method) for each subproblem. A procedure abstracts away the details of how something is done. © CS1101 (AY Semester 1)Week13 - 5

Data Abstraction Complex data should be abstracted. Java provides objects for data abstraction Object can contain other objects Objects can inherit from other objects In CS1102, you will study Abstract Data Types (ADTs) © CS1101 (AY Semester 1)Week13 - 6

Control Structures Conditionals (selection)  Execute different things depending on outcome of a test.  Examples: if-else, switch. Iteration (repetition)  Execute something repeatedly while some condition is true  Examples: for-loop, while-loop (related statements: break, continue) Recursion  Defining something in terms of itself  An alternative form of iteration  A way of thinking/paradigm © CS1101 (AY Semester 1)Week13 - 7

Object-Oriented Paradigm A way of looking at the world  A program is made up of objects.  Each object manages it own attributes (data members).  Each object has state (a set of attribute values) and behaviours (methods).  Object may interact with one another, by passing message through calling methods. © CS1101 (AY Semester 1)Week13 - 8

CS1102 Data Structures and Algorithms (1/2) CS1102 Data Structures and Algorithms.  Emphasis on algorithms and data structures  Pre-requisite: CS1101 Data structures  Lists, stacks, queues and their algorithmic designs  Trees, BSTs (Binary Search Trees)  Hash tables  Heap, priority queues  Graphs © CS1101 (AY Semester 1)Week CS1101CS1102

CS1102 Data Structures and Algorithms (2/2) Algorithms  Sorting: quicksort, mergesort, radix sort, heap sort, topological sort, etc.  Tree traversals, tree balancing  Graph depth-first and breadth-first traversals  Shortest-path algorithm (Dijkstra's algorithm) Strategies for choosing the right data structures Recursion Algorithmic analysis Big-O notation © CS1101 (AY Semester 1)Week

This Vacation Strengthen your programming skills to prepare for CS1102 © CS1101 (AY Semester 1)Week

CS2103 Software Engineering (1/2) CS2103 Software Engineering  The process of solving customers' problems by the systematic development and evolution of large, high-quality software systems within cost, time and other constraints.  Pre-requisite: CS1102  Should be familiar with algorithmic problem solving, Java and data structures. What is this course all about?  Software analysis, design, implementation and testing.  Not just coding in Java. © CS1101 (AY Semester 1)Week CS1101CS1102CS2103 or CS2261

CS2103 Software Engineering (2/2) Course objectives  To understand the software development process, including requirement analysis, design, implementation and testing.  To develop skills in object oriented approach of software development.  To understand the process of modeling real world problems using UML.  Build and test a system that illustrate the object concepts.  Familiarize with related concepts such as design patterns, various development methodologies, modularity, coherence and coupling of modules. © CS1101 (AY Semester 1)Week

CS2261 Enterprise Systems Development For IS/EC students Course objectives  To understand the software development process, including requirement analysis, design, implementation and testing.  To develop skills in object oriented approach of software development.  Similar to CS2103 but with focus on developing software systems at the enterprise level.  Technologies covered: J2EE and.NET  Topics covered: Business Information System; Enterprise Platforms; Distributed Computing Concepts; Web Services, etc. © CS1101 (AY Semester 1)Week CS1101CS1102CS2103 or CS2261

The Joys of the Craft (1/4) © CS1101 (AY Semester 1)Week Why is programming fun? What delights may its practitioner expect as his reward? First is the sheer joy of making things. As the child delights in his mud pie, so the adult enjoys building things, especially things of his own design. I think this delight must be an image of God's delight in making things, a delight shown in the distinctness and newness of each leaf and each snowflake. Second is the pleasure of making things that are useful to other people. Deep within, we want others to use our work and to find it helpful. In this respect the programming system is not essentially different from the child’s first clay pencil holder “for Daddy’s office.”

The Joys of the Craft (2/4) © CS1101 (AY Semester 1)Week Third is the fascination of fashioning complex puzzle-like objects of interlocking moving parts and watching them work in subtle cycles, playing out the consequences of principles built in from the beginning. The programmed computer has all the fascination of the pinball machine or the jukebox mechanism, carried to the ultimate. Fourth is the joy of always learning, which springs from the non- repeating nature of the task. In one way or another the problem is ever new, and its solver learns something: sometimes practical, sometimes theoretical, and sometimes both.

The Joys of the Craft (3/4) © CS1101 (AY Semester 1)Week Finally, there is the delight of working in such a tractable medium. The programmer, like the poet, works only slightly removed from pure thought-stuff. He builds his castles in the air, from air, creating by exertion of the imagination. Few media of creation are so flexible, so easy to polish and rework, so readily capable of realizing grand conceptual structures. (As we shall see later, this very tractability has its own problems.)

The Joys of the Craft (4/4) © CS1101 (AY Semester 1)Week Yet the program construct, unlike the poet’s words, is real in the sense that it moves and works, producing visible outputs separate from the construct itself. It prints results, draws pictures, produces sounds, moves arms. The magic of myth and legend has come true in our time. One types the correct incantation on a keyboard, and a display screen comes to life, showing things that never were nor could be. Programming then is fun because it gratifies creative longings built deep within us and delights sensibilities we have in common with all men. Frederic Brooks, Jr.

Past-year’s exam questions Let’s discuss some questions from AY2008/9 Semester 1 paper. © CS1101 (AY Semester 1)Week

Final Examination © CS1101 (AY Semester 1)Week

How to prepare for exams? (1/2) © CS1101 (AY Semester 1)Week

How to prepare for exams? (2/2) Preparing for Exams: A Guide for NUS Students  Every student’s nightmare exam  Contributed by Sesha Sendhil S. (see CS1101 “Chit-chat” forum) © CS1101 (AY Semester 1)Week Q. Write a program to simulate the human mind and optimize its usage. You are provided with a PC and DrJava. Requests for additional resources will not be entertained. When you are done test the program on yourself. Estimate of the time required to be spent on this exercise : Devising and writing algorithm(pseudo-code) : 3 mins Translating pseudo-code into code: 2 mins Typing in the code: In no time at all Testing and Debugging: 5 mins Total Time: 10 mins. Please submit your program using CourseMarker. If it crashes because of your submission also fix it. No additional time is allocated for this purpose.

© CS1101 (AY Semester 1)Week

End of File © CS1101 (AY Semester 1)Week