Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 9151841
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 17, 20262026-06-17T11:54:03+00:00 2026-06-17T11:54:03+00:00

Ive been racking my brain here: cout << orig << * << count <<

  • 0

Ive been racking my brain here:

cout << orig << " * " << count << endl;
string check = multiply2(orig, count);
cout << "Check was: " << check << " and number is: " << number << endl;
cout << "the compare result: " << check.compare(number) <<  endl;
if(check.compare(number) == 0)
{
  cout << "wahoo it matches!!! we did it! " << endl;
}
else
{
  cout << "Doesnt Match " << endl;
}

I’m expecting it to match and print wahoo it matches!!! we did it! but its instead saying it doesn’t match.

Here is my output:

1 * 900000
Check was: 900000 and number is: 90000
the compare result: 1
Doesnt Match

Anyone have idea why they arent matching?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-17T11:54:04+00:00Added an answer on June 17, 2026 at 11:54 am

    You compare 900000 (as in 9E5) versus 90000 (as in 9E4). Computer is right.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I've been racking my brain trying to figure this out. Here is the scenario.
I really don't know what's going on here, I've been racking my brain for
Here's a question I've been racking my brain over. Let's say I have a
I've been racking my brain for the past hour wondering how to do this.
Ive been on google all morning and here on SO. The problem im having
I've been racking my brain trying to think of the best way to access
I've been racking my brain over this for the past few days and I'm
Really racking my brain, I've been looking into this for 2+ days. Goal? Click/select
I've been racking my brain for days now, and for the life of me
I've been racking my brain (and google) over this and can't seem to find

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.