Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. General Programming
  3. C / C++ / MFC
  4. This is not visual, nor C++

This is not visual, nor C++

Scheduled Pinned Locked Moved C / C++ / MFC
c++helpcsharpdelphi
4 Posts 4 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • T Offline
    T Offline
    totig
    wrote on last edited by
    #1

    So, you may be asking yourself, with a subject like that, why use this forum? Simple, I did not go elsewhere, as codeproject always has the answer for me. Also, I know nothing of C++. Anyway, my problem. At uni, we have been told we must learn to program in C. Fair enough. But please, what environment should you use for this? I was told (though I am not sure on this) that naming your file with a .c extension, instead of .cpp should do this for you. Anyway, tried that in VS.net, and it cant find So, I tried the same code in Borland C++. It gave me some error about not giving a correct output in my function. So, you may say I am stupid, and made a mistake. But, I copied (and check often), the code from the C Language book (The bible of C I am told). Please solve this for me.

    Z P W 3 Replies Last reply
    0
    • T totig

      So, you may be asking yourself, with a subject like that, why use this forum? Simple, I did not go elsewhere, as codeproject always has the answer for me. Also, I know nothing of C++. Anyway, my problem. At uni, we have been told we must learn to program in C. Fair enough. But please, what environment should you use for this? I was told (though I am not sure on this) that naming your file with a .c extension, instead of .cpp should do this for you. Anyway, tried that in VS.net, and it cant find So, I tried the same code in Borland C++. It gave me some error about not giving a correct output in my function. So, you may say I am stupid, and made a mistake. But, I copied (and check often), the code from the C Language book (The bible of C I am told). Please solve this for me.

      Z Offline
      Z Offline
      ZoogieZork
      wrote on last edited by
      #2

      What is the exact code you are trying to compile? It is strange that stdio.h could not be found. Sounds like you may have an incomplete or corrupted installation of VS.NET. - Mike

      1 Reply Last reply
      0
      • T totig

        So, you may be asking yourself, with a subject like that, why use this forum? Simple, I did not go elsewhere, as codeproject always has the answer for me. Also, I know nothing of C++. Anyway, my problem. At uni, we have been told we must learn to program in C. Fair enough. But please, what environment should you use for this? I was told (though I am not sure on this) that naming your file with a .c extension, instead of .cpp should do this for you. Anyway, tried that in VS.net, and it cant find So, I tried the same code in Borland C++. It gave me some error about not giving a correct output in my function. So, you may say I am stupid, and made a mistake. But, I copied (and check often), the code from the C Language book (The bible of C I am told). Please solve this for me.

        P Offline
        P Offline
        Paul Oss
        wrote on last edited by
        #3

        It depends on what the Uni provides. Back in my day, the universities often steadfastly refused to acknowledge the existence of windows, so you were often doing c programming from a unix prompt with a shell account using the... help me out here.. cc compiler? Ie cc source.c target or some such command line. They're going to have to guide you on an environment, because eventually you'll be writing programs and swapping source files and if they don't work in all environs, you'll be wasting your time. My second guess is that they're going to at least start you with pure ANSI c and c++, so TECHNICALLY the environment may not matter as long as you understand your personally chosen environment. In Visual Studio, you can write console programs and stick to completely ANSI code and have no trouble whatsoever. In the Borland environment-- I have no idea. Hope this helps. As far as your particular error, you might send a snippet of code which directly relates to your error. Paul

        1 Reply Last reply
        0
        • T totig

          So, you may be asking yourself, with a subject like that, why use this forum? Simple, I did not go elsewhere, as codeproject always has the answer for me. Also, I know nothing of C++. Anyway, my problem. At uni, we have been told we must learn to program in C. Fair enough. But please, what environment should you use for this? I was told (though I am not sure on this) that naming your file with a .c extension, instead of .cpp should do this for you. Anyway, tried that in VS.net, and it cant find So, I tried the same code in Borland C++. It gave me some error about not giving a correct output in my function. So, you may say I am stupid, and made a mistake. But, I copied (and check often), the code from the C Language book (The bible of C I am told). Please solve this for me.

          W Offline
          W Offline
          W Hammer sledge
          wrote on last edited by
          #4

          If you want to test code from Kerningham and Ritchie, you can use VC of course. All you have to do is (VC6) First: click on File - New you can now choose the type of project you want to create select WIN32console application name it test (the IDE will append .dsw) click OK Second: Select File - New again you can now choose then type of file vou want to create select sourcecode (.cpp) name it main (the IDE will append .cpp) click OK Now you can cut and paste your sourcecode to the main.cpp file and compile it. (usually the first test would be compiling "Hello World") sledge

          1 Reply Last reply
          0
          Reply
          • Reply as topic
          Log in to reply
          • Oldest to Newest
          • Newest to Oldest
          • Most Votes


          • Login

          • Don't have an account? Register

          • Login or register to search.
          • First post
            Last post
          0
          • Categories
          • Recent
          • Tags
          • Popular
          • World
          • Users
          • Groups