hi! i am trying to write a program that takes a long integer and compares every pair in that integer and displays largest pair. e.g we have an integer 23812 and in this integer largest pair is 81. so program should display 81. but i have no logic in mind for this program. please help me
hAbbas
0
Newbie Poster
Recommended Answers
Jump to Post
- Convert number to string.
- Create array of pairs in the string.
- Convert array members to integers.
- Iterate array to find largest member.
Jump to Posthi! rubber man. actually i and my friend are trying to solve this problem. i have a confusion that how to create pairs in the string. plz guide me
All 5 Replies
rubberman
1,355
Nearly a Posting Virtuoso
Featured Poster
Saboor880
9
Junior Poster
rubberman
1,355
Nearly a Posting Virtuoso
Featured Poster
uonsin
-2
Newbie Poster
cheryllocascio
0
Newbie Poster
Be a part of the DaniWeb community
We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.