11 weeks (number of replies) and 11 weeks

Source: Internet
Author: User

11 weeks (number of replies) and 11 weeks

/*

* Copyright (c) 2014, computer College, Yantai University

* All rights reserved.

* File name: test. cpp

* Author: Wang Zhong

* Completion date: January 1, November 10, 2014

* Version No.: v1.0

*

* Problem description: determines whether the parameter is a return number;

* Input Description: enter a number;

* Program output: determines and outputs whether the number is a return value;


# Include <iostream> using namespace std; bool isPalindrome (int); int main () {int m; cin> m; if (isPalindrome (m )) cout <m <"indicates the number of input files. Thank you! "<Endl; else cout <m <" is not the number of replies. What's better! "<Endl; return 0;} bool isPalindrome (int n) {int s = 0, r, x = n; while (x> 0) {r = x % 10; s = s * 10 + r; x = x/10;} return (s = n );}


 

 

 

 

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.