Fortune Telling Collection - Free divination - How to draw a flow chart
How to draw a flow chart
(1) Convert feet to meters.
(2) Input the coordinates of two points, find the distance between two points and output.
2. Branch program
(1) Describe the plan for tonight: If it snows, play with snow on campus; Otherwise, get on the plane 103 (miss)
(2) toss a coin tonight: heads, karaoke; Tail: shopping; Stand up and learn C++
(3) Find the function value:
(4) Input the coefficients of the unary quadratic equation AX 2+BX+C = 0, and solve them respectively according to the values of the coefficients (consider the possibility that the coefficients are too complicated, reduce the difficulty for yourself, and ignore the beginning of direct solution of the system).
(5) Enter the individual's total monthly income, and calculate the taxable amount and after-tax income of this month (refer to the task in week 9 for the tax rate).
3. Ring structure
(1) Find 1+2+3+...+ 100 (all three loop structures are drawn).
(2) Output the result of1/3-3/5+5/7-7/9 …+19/21.
(3) If a number is exactly equal to the sum of its factors, it is called "perfect number". Find all perfect numbers within 1000.
(4) Output all palindromes within 1000.
(5) A rooster is worth five dollars, a hen is worth three dollars, and a chicken is worth one dollar or one hundred dollars to buy a hundred chickens. How to buy?
4, the complex structure of the program
In solving problems, using functions allows us to think in a more "orderly" way, "top-down, step by step", and think in truth. Example: The following flowchart is used to output an asterisk chart, which reflects this idea. The right picture can be embedded in the left picture instead of the box of "output line I", or it can guide us to compile a function specially.
Task:
(1) outputs all palindrome prime numbers within 10000. Draw a judgment palindrome and a judgment prime number respectively, and realize these two functions by applying functions.
(2) Draw the flow chart of the banking system (it is not necessary to draw all the specific businesses)
- Previous article:Circumstances describe the emotions of characters.
- Next article:Is Oracle Bone Inscriptions a Memory of the World Register?
- Related articles
- When did the couple get their son's husband's birthday in the solar calendar: 1990.9. 16. Wife's birthday in the solar calendar: 1992.2.6?
- What is a constellation?
- My tarot spirit disappeared for no reason. Who can help me and tell me how to do it?
- What do Tai Chi and Eight Diagrams mean?
- Which school is better to learn the Book of Changes?
- What color is the shining unicorn?
- What ancient poems are given to the twelve constellations?
- The released version of isu.
- From Shang Yang to Qin's unification of China, which monarchs were there in turn?
- Introduction of Street Fighter 5DLC Maynett