Thread: AI Programming language

  1. #31
    Registered User knightjp's Avatar
    Join Date
    Nov 2008
    Location
    Dubai, U.A.E.
    Posts
    15
    Quote Originally Posted by Elysia View Post
    What does manage RAM usage mean?
    You use what resources you need and free them when you don't need them. Otherwise you get a memory leak.
    Do you have to do memory management manually in C++? No, you can use smart pointers to handle that for you.
    Well I've installed and used quite a few programs and what I've noticed is that some of them use up quite a bit of resources and some don't. I noticed that the reason for the Mac OS being so fast and efficient is the fact that its designed to use the least amount of processes for a given task, making the resource usage low.
    I wanted to know if that was possible in C++.

  2. #32
    C++まいる!Cをこわせ!
    Join Date
    Oct 2007
    Location
    Inside my computer
    Posts
    24,654
    The applications themselves are responsible for the memory usage. If they allocate a lot of memory, then of course those digits rise.
    This has nothing to do with language and all about how memory hungry your program is - and it is as memory hungry as you design it to be.
    Quote Originally Posted by Adak View Post
    io.h certainly IS included in some modern compilers. It is no longer part of the standard for C, but it is nevertheless, included in the very latest Pelles C versions.
    Quote Originally Posted by Salem View Post
    You mean it's included as a crutch to help ancient programmers limp along without them having to relearn too much.

    Outside of your DOS world, your header file is meaningless.

  3. #33
    Registered User knightjp's Avatar
    Join Date
    Nov 2008
    Location
    Dubai, U.A.E.
    Posts
    15
    Quote Originally Posted by Elysia View Post
    The applications themselves are responsible for the memory usage. If they allocate a lot of memory, then of course those digits rise.
    This has nothing to do with language and all about how memory hungry your program is - and it is as memory hungry as you design it to be.
    Thanks for the clarification. Do you think its wise to study C and then move to C++ or just straight away go to C++ at once?

  4. #34
    C++まいる!Cをこわせ!
    Join Date
    Oct 2007
    Location
    Inside my computer
    Posts
    24,654
    No, they are two different languages. If you wish to pick C++, then you should go straight for it.
    Likewise for C.
    Quote Originally Posted by Adak View Post
    io.h certainly IS included in some modern compilers. It is no longer part of the standard for C, but it is nevertheless, included in the very latest Pelles C versions.
    Quote Originally Posted by Salem View Post
    You mean it's included as a crutch to help ancient programmers limp along without them having to relearn too much.

    Outside of your DOS world, your header file is meaningless.

  5. #35
    & the hat of GPL slaying Thantos's Avatar
    Join Date
    Sep 2001
    Posts
    5,681
    Considering development time is not an issue with me (as this is a personal hobby project) and my program will be something of a robot like thing.
    That really doesn't narrow down what you are going to do with it. AI is a pretty broad term.

    Things like motor control, sensor inputs, timers, etc should probably be done in C. Now depending on what you are going to do with it a higher level language might be useful for higher level functions. Prolog might be a good one to check out as it is designed around logic, but that depends heavily on the processor power and time requirements.

    One thing I would definitely do is to ignore Elysia in any C vs C++ debates. He/she/it apparently can not see that there are times when C is the best language to use for a given situation.

  6. #36
    C++まいる!Cをこわせ!
    Join Date
    Oct 2007
    Location
    Inside my computer
    Posts
    24,654
    Quote Originally Posted by Thantos View Post
    Things like motor control, sensor inputs, timers, etc should probably be done in C.
    Now that just boggles the mind. If something can be done in a higher language, then it should be done. Unless you are limited to one by tools or such.

    One thing I would definitely do is to ignore Elysia in any C vs C++ debates. He/she/it apparently can not see that there are times when C is the best language to use for a given situation.
    It. I like that!
    There are never times when C is best. There are only times when you are forced to C.
    That is, in a view for you, the developer, not the implementor.
    Quote Originally Posted by Adak View Post
    io.h certainly IS included in some modern compilers. It is no longer part of the standard for C, but it is nevertheless, included in the very latest Pelles C versions.
    Quote Originally Posted by Salem View Post
    You mean it's included as a crutch to help ancient programmers limp along without them having to relearn too much.

    Outside of your DOS world, your header file is meaningless.

  7. #37
    & the hat of GPL slaying Thantos's Avatar
    Join Date
    Sep 2001
    Posts
    5,681
    Thank you for proving my point.

  8. #38
    C++まいる!Cをこわせ!
    Join Date
    Oct 2007
    Location
    Inside my computer
    Posts
    24,654
    There, there. We don't disagree, then.
    Quote Originally Posted by Adak View Post
    io.h certainly IS included in some modern compilers. It is no longer part of the standard for C, but it is nevertheless, included in the very latest Pelles C versions.
    Quote Originally Posted by Salem View Post
    You mean it's included as a crutch to help ancient programmers limp along without them having to relearn too much.

    Outside of your DOS world, your header file is meaningless.

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Why C Matters
    By DavidP in forum A Brief History of Cprogramming.com
    Replies: 136
    Last Post: 01-16-2008, 09:09 AM
  2. chess ai contest
    By Raven Arkadon in forum Contests Board
    Replies: 7
    Last Post: 07-09-2005, 06:38 AM
  3. AI Contest Proposal
    By MadCow257 in forum Contests Board
    Replies: 4
    Last Post: 03-13-2005, 03:27 PM
  4. Language of choice after C++
    By gandalf_bar in forum A Brief History of Cprogramming.com
    Replies: 47
    Last Post: 06-15-2004, 01:20 AM
  5. Game Design Topic #1 - AI Behavior
    By TechWins in forum Game Programming
    Replies: 13
    Last Post: 10-11-2002, 10:35 AM