Click here to load reader

DATA STRUCTURE

  • Upload
    libba

  • View
    60

  • Download
    0

Embed Size (px)

DESCRIPTION

FP 305. DATA STRUCTURE. By : Suzila Yusof. INTRODUCTION TO DATA  STRUCTURES AND ALGORITHMS. Mathematic. Study of Computer Science. Science. Engineering. Continuance. A mathematical formulation expert. Computer Scientists. Know the scientific and systematic methods. - PowerPoint PPT Presentation

Citation preview

Slide 1

DATA STRUCTUREFP 305By :Suzila YusofINTRODUCTIONTODATASTRUCTURESANDALGORITHMSStudy of Computer ScienceScienceMathematicEngineeringContinuanceComputer ScientistsCreative thinking in the design of algorithms and selecting the approriate data structureKnow the scientific and systematic methodsA mathematical formulation expertcontinuanceAlgorithmData StructuresComputer TroubleshootingThe selection ofdatastructures&key-toalgorithm=effectivenesseds.problems:storage space&runtimeintroductiontoalgorithmsAlgorithmsConducts a series of structured, step by step to solve the problemData StructuresMethods for compiling the data to be processed by computerIn SK, the algorithms is a sequence of introductions to a computer that provides logical solutions to a problem. It involves operations on data collection.ContinuanceStructured AlgorithmsSequence : the sequence of each step performed step by stepRepeat / Loop : one or more steps executed repeatedlyOptions : one of several implementation options will be selected and implementedEasy to read, understood, analyzed and corrected (error)>effectiveContinuanceAlgorithmswritteninvariousforms:humannatural language,pseudocode,flow chartor programming languagessuch asPascal,C,C++, etc.ContinuanceImportant Feature of the algorithmsEach direction is clearHave input, to begin implementationHas an output, the result of the implementationCan run when the tool or effectiveA finite solution (no finish)Case studiesProblem to determine and print the largest number between two numbers are read from the keyboardAlgorithms :Comparing the two numbers to get the greatest value.

Solution using :Human nature languageFlow chartNatural languageRead number1 and number 2If the number1 is greater than the number22.1 Printing a message number greater than the number23. If number2 is greater than the number1 3.1 Printing messages larger than the number2 and number14.If conditions 2 and 3 is not true 4.1 Printing messages number1 and number2 is the same value5.Finish

Flow chartSTARTENDBACA nomborCETAKnombor1=nombor2CETAK nombor2 > Nombor1CETAK nombor1 > Nombor2JIKA nombor1 > nombor2JIKA nombor2 > nombor1YaYaTidakTidakintroductiontodata structureAlgorithmsConducts a series of structured, step by step to solve the problemAlgorithmsConducts a series of structured, step by step to solve the problemCombination of data values which are based on structured that will form the data structure. Several sets of operations can be performed on the data structure.ContinuanceDATA STRUCTUREStorage StructureStructural RelationshipStructural ConditionsLink StructuresStorage structureControl the layout of data in memory directly divided into two types :ArrayRecord or structurelink structureForconnectinganode(astructuralarrangement of data,usuallyinthe form ofrecords)toother nodes. Relatednodescan bedoneinlinearornonlinear.Example-linkedlist- tree- graphStructure conditionsStructuralconditionstodescribe thetasksthatoccurinaprocess that occursin thereal world.Example-Stack-QueueStructure relationship

Implement thekeyrelationshipbetweenaccess andotherdatatofacilitatesearchoperations.Example-Table-Searchtree

Basic DataAbstract DataData TypesMobile Data (Simple Data Types)Pointer Data (Pointer)Structured dataChoice of dataChoice of DataDepending on the valueto be represented by the variableOfage-integerdatatypesStudent's name-the variablearrayof type charactersimple data typesThedatatypecan onlystoreonevalue.Divided intotwotypes:-Pre-definedatatypesdatatypesdefinedbyprogramming languages such asint:integerdatatype,char:characterdatatype, etc.-User-definedatatypesuser-defineddatatype isdefinedby the programmerdataasnumericdatatypes(enumerateddatatypes)pointer data typesUser-defineddatatypesdepending on thetype of dataisaccusedby thepointervariables(as determinedbythe user)structured data typesType ofdatathatcan bedefinedbythe user.For example:arraysandstructuresabstract data typesModelinganobjectfromthe real worldoperations. Ofthismodel,datastructurebuiltbyprogrammer usingsometype ofdataavailable.eglinkedlist,stack,queueandtree