as a rule it is DESTINATION before SOURCE?

This is a discussion on as a rule it is DESTINATION before SOURCE? within the C++ Programming forums, part of the General Programming Boards category; when are you are trying to remember parameters does the destination always come before source? Here are some examples that ...

  1. #1
    Shadow12345
    Guest

    as a rule it is DESTINATION before SOURCE?

    when are you are trying to remember parameters does the destination always come before source? Here are some examples that would say that is true:

    strncpy(char *destination, char *source, size)
    fread(destination, size, size, sourcefile)
    memcpy(destination, source, size)

    are there any (ansi)standard functions that don't have the destination,source set up or can I just assume that destination is always before source

    i ask this because i have been running into a lot of functions that need copying of sorts

    thanks

  2. #2
    Registered User
    Join Date
    Aug 2002
    Posts
    170
    I know that it is prety common. Like one of my favorite functions.

    sprintf(destination,"%s %d", "Sesame Street(tm) was brought to you by the number:", 7);
    Best Regards,

    Bonkey

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. How to build, run Boland C++ 6 source file via VS2005?
    By userpingz in forum C++ Programming
    Replies: 2
    Last Post: 05-21-2009, 04:25 AM
  2. Debug into Source
    By lehe in forum C++ Programming
    Replies: 4
    Last Post: 02-18-2009, 10:45 AM
  3. Binary Search Trees Part III
    By Prelude in forum A Brief History of Cprogramming.com
    Replies: 16
    Last Post: 10-02-2004, 04:00 PM
  4. blending
    By linuxdude in forum Game Programming
    Replies: 4
    Last Post: 06-22-2004, 12:25 AM
  5. Tutorial review
    By Prelude in forum A Brief History of Cprogramming.com
    Replies: 11
    Last Post: 03-22-2004, 09:40 PM

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21