20172305 2018-2019-1 "Java software architecture and data structure" first week study summary

Source: Internet
Author: User
Tags cpu usage

20172305 2018-2019-1 "Java software architecture and data structure" the first week of learning summary textbook study content this week is mainly about the contents of the first and second chapters of the book:
    • Chapter I.
      • Software quality:
        • Accuracy (the degree to which the software meets specific requirements)
        • Reliability (frequency and degree of damage to software failure)
        • Robustness (good handling of error conditions)
        • Availability (how easy it is for users to master and run tasks in the software)
        • Maintainability (how easy the software is to make modifications)
        • Reusability (the ease with which software components can be exploited by other software systems)
        • Portability (software composition can be easily used in a variety of computer environments)
        • Operational efficiency (the degree to which the software accomplishes its objectives without wasting resources)
      • Data structures (how computers store and organize data): Array stack queue list binary tree hash table heap diagram
      • program = data structure + algorithm
      • Software = Program Plus software engineering
    • Chapter II
      • Algorithm analysis
      • Large o notation (essentially a response to the development trend of algorithmic complexity)

      • Growth function: Indicates the relationship between the size of the problem (n) and the value we want to optimize
        • Time complexity (quantitative description of the algorithm's run time)--CPU usage time
        • Space complexity (size of memory required to run a program)--Memory space
      • The progressive complexity is called the Order of the algorithm (ignoring constants and other minor items in the growth function of the algorithm, only the main items are retained)

Problems in teaching materials learning and the solving process
  • Issue 1: increasing CPU speed does not necessarily improve processing speed
  • Problem 1 Solution: The Order of the algorithm is constant [that is, the complexity is O (1)] or the linear order [that is, the complexity is O (n)], the increase in CPU speed will linearly improve processing speed. With the increase of the complexity of the algorithm, the speed of the processor has a smaller influence on the complexity. Different complexity, in the increase of the same speed of the processor, its operating efficiency is different.
  • Issue 2: Analysis of time complexity
  • Problem 2 Solution:
    • The time complexity of the loop is equal to the complexity of the loop body multiplied by the number of times the loop runs. time complexity O (n)
    for(int count = 0;count<n;count++){//*复杂度为O(1)的步骤系列}
    • When loops appear nested, the complexity of the loop is equal to the complexity of the inner loop multiplied by the complexity of the outer loop. time Complexity O (n^2)
    for(int count = 0;count < n;count++){   for(int count2 = 0;count2<n;count2++)   {       //复杂度为O(1)的步骤系列   }}
    • the complexity of the method invocation takes into account the order of the loop body and the order of the calling method. time Complexity O (n^2)
    for(int count = 0;count<n;count++){    printsum(count);}
    public void printsum(int count){    int sum = 0;    for(int I = 1;I<count;I++)        sum += I;    System.out.println(sum);}
    • Summarize:
  • Issue 3: Comparison of growth functions
  • Solution to Problem 3: graph of growth function functions
    • When n is smaller:
    • n When larger:
    • Conclusion: C < log2n < n < n * log2n < n^2 < N^3 < 2^n < 3^n < n!
    • (1) What is the order of the following growth functions?
    • (2) Please determine the growth function and order of the code snippet below
    • Answer:
    • (3) Please determine the growth function and order of the code snippet below
    • Answer:
Pair and peer reviews (Wang Yuhan)
    • Blogs that are worth learning or questions:
      • No problem, very perfect blog.
    • Based on the scoring criteria, I scored this blog: 5 points.
      • The score is as follows:
      • Correct use of markdown syntax (plus 1 points)
      • Complete features in the template (plus 1 points)
      • Problem and solution process in textbook learning, one question plus 1 points
      • Problem and resolution in code debugging, no problem
      • Feelings, experience is not false big empty plus 1 points
      • Reviews seriously, can point out the blog and the code of the problem in addition to 1 points
Reviews (Fang)
    • Blogs that are worth learning or questions:
      • The picture is used properly and clearly explains the problem and the relevant content
    • Based on the scoring criteria, I scored this blog: 6 points.
    • The score is as follows:
      • Correct use of markdown syntax (plus 1 points)
      • Complete features in the template (plus 1 points)
      • Problems and solving process in textbook learning, two questions plus 2 points
      • Problems in code debugging and resolution process, no problem
      • Feelings, experience is not false big empty plus 1 points
      • Reviews seriously, can point out the blog and the code of the problem in addition to 1 points
Mutual evaluation of objects
    • This week's study of the knot
      20172304 Fang
      20172323 Wang Yuhan

    • Pair learning content: Software quality algorithm analysis growth function large O notation time complexity space complexity

Sentiment
本学期的第一篇博客,又到当初写博客的时候了(?_?)。一口气学了两章内容,好在两章内容不是很多,随便翻了一下书,发现大部分是栈、队列以及链表之类的,开始系统的学习算法结构与分析。假期里做了几个程序没有让自己忘了太多的内容,捡起来也会容易得多。上学期在程序设计的课上取得满分,所以这学期要保持上学期的精神状态继续学习。作为新大二的学生,我更要为新大一的学弟学妹做个好头。加油!(? ??_??)?
Learning progress Bar
lines of code (new/cumulative) Blog Volume (Add/accumulate) Learning Time (new/cumulative) Important Growth
Goal 5000 rows 30 Articles 400 hours
First week 0/0 1/1 15/15
Resources
    • Software Quality
    • Analysis of complexity

20172305 2018-2019-1 "Java software architecture and data structure" first week study summary

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.