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 7868695
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 3, 20262026-06-03T01:04:53+00:00 2026-06-03T01:04:53+00:00

I wrote a very basic program but was not able to understand the behaviour

  • 0

I wrote a very basic program but was not able to understand the behaviour of it.

     # include<stdio.h>
     # include<iostream.h>
     # include<conio.h>

     using namespace std;
     int main()
     {
       cout << "50" << oct <<"50" << hex <<"50" << abc << "50";// error abc not defined
       cout << "50" << oct <<"50" << hex <<"50"; // No error output 505050
       getch();   
    } 

Are oct and hex defined as some macro in any of the files that I have included which is the reason why I don’t get an error for second cout statement?

  • 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-03T01:04:55+00:00Added an answer on June 3, 2026 at 1:04 am

    oct and hex are stream manipulators defined in <ios>, whereas abc is not a symbol defined in any of the Standard header. Hence you see the error about only abc as you’ve not declared it yourself in your program.

    Apart from that it seems that you’re using very old compiler which comes with <iostream.h>. I would suggest you to update your compiler (or switch to better compiler), and use <iostream> instead of <iostream.h> which is not Standard header.

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

Sidebar

Related Questions

This is a very basic question for JUnit testing. I wrote a program which
I'm trying to write a very basic macro in VB for Microsoft Word, but
I'm very new to C#. My boss asked me to wrote some code using
I wrote this very basic programm to examine what the compiler is doing behind
I want to compile a very basic hello world level Cuda program under Linux.
I'm encountering a very strange problem using g++ 4.1.2. I have a very basic
I wrote a custom (VERY basic Hello world!) bootloader in Assembler and I would
I'm learning how to program the video camera in android and wrote a very
I am trying to solve the question below, but I do not understand it
This is a very basic program for Uni which writes user data to a

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.