Pair programming project: Small early math learning software with high UI summary

Required functions implemented:

1, user registration function. The user's phone number, click on the registration will receive a registration code, the user can use this registration code to complete the registration;

2, after the completion of user registration, password prompt interface, user input password matches the password twice after the success. 6-10 password, the case must contain letters and numbers. Users can change the password, enter the correct password in the log in the original state, change your password after successfully re-enter the same new password twice;

3, after the password has been set, jump to the selection interface, display interface elementary, middle and high school three options, the user clicks on one of them, prompting the user to enter the number of items need to be generated;

4, after the user enters the number of items, generating a paper (with a roll can not have the same title, all entitled multiple choice), the interface displays the first question and casual working four options, the user selects one of the four options submission interface displays the second question, ... , until the last question;

5, after the submission of the last question, the display interface, the score is calculated based on the percentage of correct answers;

6, the user interface can opt out of the score or continue to do problems;

7, small high math problem and asked to see the beginning of a personal project.

 Requirements analysis and design ideas:

The project adds ui interface compared with the previous personal project and calculate the answer and score function, my division was calculated to generate an answer that is the subject of back-end content.

The main issue I need to address is the subject of computing, logic is first of all the question can be reused, just calculate the answer for each question, and save it.

After obtaining the title, I think the first task is to remove the expression '√' and other unilateral operator, converted into four floating-point arithmetic pure.

Second, four floating point arithmetic can postfix i.e. reverse Polish calculated neutral conjugated converted to:

 

A common sequence in an expression converted to a reverse Polish notation general algorithm is:

 

First you need to allocate two stacks, as a temporary storage operator stack S1 (including the end of a symbol), as an input a reverse Polish stack S2 (empty stack), the stack may be first placed Sl lowest priority operators # , note should end this type infix lowest priority of operators. You can specify other characters, not necessarily non-#. From the left end of the take-conjugated type character sequence carried out by the following steps:

 

(1) If the fetched character is an operand , a complete analysis of the operand, the operand stack directly into S2

 

(2) If the fetched character is the operator , then the operator stack with the top element S1, and if the operator precedence (not including the bracket operator) is larger than S1 stack stack operator precedence, then the S1 operator into the stack, otherwise, the operators S1 stack pop stack, the stack into the S2, S1 stack until the stack below the operator (not equal to) the priority of the operator, and finally sent to the operator S1 into the stack.

 

(3) If the fetched character is "(", directly into the top of the stack S1.

 

(4) If the fetched character is ")", the nearest distance S1 stack stack "(" between the operator, one by one out of the stack , the stack S2 is fed successively, then discard "(."

 

(5) Repeat steps 1-4 until all the input characters have been processed

 

(6) If the fetched character is "#", all operators will be within the stack S1 (not including the "#"), one by one out of the stack, the stack S2 is fed sequentially.

 

Completing the above steps, S2 stack is then reverse Polish notation output. But what should be done in reverse order processing S2. It can be calculated according to the calculation method of Reverse Polish Notation!
legend:

 

 

 

 

 

 

 

 After conversion may be calculated inverse Polish, and a new expression, or if the current character variable is a number, push, if the operator, then the pop top two stack elements for the corresponding operation, and the result stack, Finally, when expression after scanning, the stack is the result.

Finally, the option can be generated.

 

Then I was also involved in the implementation part to send SMS verification code, because the cloud Ali did not give a c ++ of DEMO, and therefore had to search online solution, you can refer to:

https://blog.csdn.net/print_out/article/details/89420314

After the final I signed up for an account in the cloud Ali opened the SMS function of various parameters into the function where you can receive text messages properly.

 

 

 

 

 

 

 

Summary and thoughts:

  The pair programming project was significantly much larger than the individual projects, therefore, the test of strength and with two more, and half way out of the problem is a lot, through their own thinking and query data and network, one resolve, feel

Or gain a lot, let me feel the importance of cooperation. And I believe I believe our cooperation will become increasingly important in the next team project.

Guess you like

Origin www.cnblogs.com/xwyzy/p/11604973.html