-5

fatal error: iostream.h: No such file or directory

Why code blocks returned this error after compile

I'm a beginner in C++

halfer
  • 19,824
  • 17
  • 99
  • 186
  • 1
    It should be `#include ` – drescherjm Oct 28 '19 at 18:58
  • 6
    There is no `iostream.h` in C++. If you learned C++ using TurboC++ then I regret to inform you that most of what you have learned is out of date and should pretty much be thrown out. – NathanOliver Oct 28 '19 at 18:59
  • Possible duplicate of [iostream file not found in Code::Blocks](https://stackoverflow.com/questions/50818958/iostream-file-not-found-in-codeblocks) –  Oct 28 '19 at 19:02
  • Also: https://stackoverflow.com/q/50504352/10957435 –  Oct 28 '19 at 19:02
  • @Chipster Neither of those are correct. This question is about missing `` (which is an old non-standard header), not missing `` – NathanOliver Oct 28 '19 at 19:05
  • @NathanOliver Ah. Sorry. I knew I had seen something similar before and kind of just pounced. –  Oct 28 '19 at 19:06
  • Where is your code?! – AbdelAziz AbdelLatef Oct 28 '19 at 19:17
  • 1
    Likely the Reverse-Duplicate: [Why doesn't a simple “Hello World”-style program compile with Turbo C++?](https://stackoverflow.com/questions/44863062/why-doesnt-a-simple-hello-world-style-program-compile-with-turbo-c) – user4581301 Oct 28 '19 at 19:24

2 Answers2

0

In C++, You need to Include iostream without the 'h'

See More Information here http://www.cplusplus.com/reference/iostream/

0

use only #include<iostream> as #include<iostream.h> works in old compiler like turbo c++.

drescherjm
  • 10,365
  • 5
  • 44
  • 64