1034:c Language Programming Tutorial (third Edition) after class exercise 8.8

Source: Internet
Author: User

The title description writes a function, entering a four-digit number, which requires the output of these four numeric characters, but spaces between each of the two digits. If you enter 1990, you should output "1 9 9 0". Enter a four-digit output to increase the space output sample input
1990
Sample output




1#include <stdio.h>2 3 voidFuncintN)4 {5     intGE = nTen;6     intQian = n/ +;7     intBai = (N-qian * +) / -; 8     intShi = (N-qian * +-Bai * -) /Ten; 9 Tenprintf"%d %d%d%d\n", Qian, Bai, Shi, ge); One } A  - intMainintargcChar Const*argv[]) - { the     intnum; -      -scanf"%d", &num); -  + func (num); -  +     return 0; A}

1034:c Language Programming Tutorial (third Edition) after class exercise 8.8

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.