Similar to the increase in yu'e Bao numeric animation, yu'e Bao numeric Animation

Source: Internet
Author: User

Similar to the increase in yu'e Bao numeric animation, yu'e Bao numeric Animation

There is a need for an animation similar to the increase in yu'e Bao values in recent projects:

Demo


// Start the timer [NSTimer scheduledTimerWithTimeInterval: 0.001 target: self selector: @ selector (timerFireMethod :) userInfo: nil repeats: YES];

/*** @ Brief Timing Method ** @ param theTimerP NSTimer */# pragma mark-timing method-(void) timerFireMethod :( NSTimer *) theTimerP {// determine the average added value float aver = 1 based on the value size; if (self. result> 1000) {aver = 100;} else if (self. result> 100) {aver = 200;} else if (self. result> 10) {aver = 500;} else {aver = 800;} // increase the average self. index + = self. result/aver; // determines whether a random value is reached. if (self. index <self. result) {// determine whether the random number is less than 10 if (self. result <= 10) {// if the value is less than or equal to 10, the two digits after the decimal point are displayed. lab. text = [NSString stringWithFormat: @ "%. 2f ", self. index];} else {// otherwise, the scale self is not displayed when you increase the number. lab. text = [NSString stringWithFormat: @ "%. 0f ", self. index] ;}} else {// reaches a random value // The start value is set to the initial value self. index = 0; // The tag is set to a random value self. lab. text = [NSString stringWithFormat: @ "%. 0f ", self. result]; // disable the timer [theTimerP invalidate];}



The calculation formula of yuebao is less than the actual value.

Isn't your money transferred once? The funds transferred to yu'e Bao are not profitable on the current day. Generally, the funds are extended by one business day, that is, the third business day.

What is the benefit of yu'e Bao in 2014?

In the future, yu'e Bao's deposit amount will decrease, the amount of withdrawals will increase, and the limit on the bank will increase. Therefore, yu'e Bao's income is expected to fall to the interest rate of about 5%, this is the normal income range of the monetary fund.

Related Article

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.