Thread: What are macros and why build your own c library?

Threaded View

Previous Post Previous Post   Next Post Next Post
  1. #2
    Registered User
    Join Date
    May 2009
    Posts
    4,183
    Quote Originally Posted by Sankait Laroiya View Post
    Hello guys, I came across a word MACRO, what does it mean in programming?
    In C macros are divided into MACRO constants and MACRO that take parameters.

    The MACRO constants are used to avoid doing magic number programming [constants].
    Magic number (programming) - Wikipedia, the free encyclopedia

    Edit2: Look up the "#define" for more info on MACROs

    Edit3: http://en.wikipedia.org/wiki/C_preprocessor

    MACRO that take parameters are too complex for me to explain to anyone; esp. to a newbie C programmer.

    Quote Originally Posted by Sankait Laroiya View Post
    And why people create their own c libraries?
    They do it in order to make useful programs that are NOT tiny.
    They do it in order to reuse the code/libraries.
    They do it to avoid using other people library they do NOT wish to use.
    They do it to avoid re-inventing the wheel in every program they write.

    Tim S.
    Last edited by stahta01; 09-24-2014 at 05:49 AM.
    "...a computer is a stupid machine with the ability to do incredibly smart things, while computer programmers are smart people with the ability to do incredibly stupid things. They are,in short, a perfect match.." Bill Bryson

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Replies: 9
    Last Post: 02-08-2012, 10:23 PM
  2. Error in Exceptions.h file during build of QuickFix library
    By arupsarkar in forum C++ Programming
    Replies: 3
    Last Post: 07-16-2010, 10:30 AM
  3. Macros inside of macros
    By Chewie8 in forum C Programming
    Replies: 2
    Last Post: 02-24-2008, 03:51 AM
  4. Replies: 19
    Last Post: 01-12-2006, 11:04 AM
  5. Library build path
    By aker_y3k in forum C++ Programming
    Replies: 7
    Last Post: 10-05-2002, 12:46 AM