DaemonForums  

Go Back   DaemonForums > FreeBSD > FreeBSD General

FreeBSD General Other questions regarding FreeBSD which do not fit in any of the categories below.

Reply
 
Thread Tools Display Modes
  #1   (View Single Post)  
Old 4th September 2011
sharris sharris is offline
Package Pilot
 
Join Date: Jun 2010
Posts: 146
Default echo and print ?

Would anyone know which is the fastest between echo and print and why? Also is one safer to use than the other? If so, why?

Thanks in advance
Reply With Quote
  #2   (View Single Post)  
Old 4th September 2011
vermaden's Avatar
vermaden vermaden is offline
Administrator
 
Join Date: Apr 2008
Location: pl_PL.lodz
Posts: 1,056
Default

Code:
% print a
a
% echo a
a
% which print
print: shell built-in command
% which echo
echo: shell built-in command
Same speed, both built-in.

Take a look on printf which has different functionality then echo/print.
__________________
religions, worst damnation of mankind
"If 386BSD had been available when I started on Linux, Linux would probably never had happened." Linus Torvalds

Linux is not UNIX! Face it! It is not an insult. It is fact: GNU is a recursive acronym for “GNU's Not UNIX”.
vermaden's: links resources deviantart spreadbsd
Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Shell script: echo something to stderr Carpetsmoker Programming 4 28th June 2010 09:04 PM
echo tcpdump date to an output bsdnewbie999 Programming 8 8th April 2009 02:58 PM
Windows scripts can't print drhowarddrfine Other OS 15 31st March 2009 08:53 AM
Print on remote WinXP from web host drhowarddrfine General software and network 5 13th October 2008 05:41 PM
FBSD emulating pdc w/ AD, exchange and print server? cgc2 FreeBSD General 9 16th July 2008 04:14 PM


All times are GMT. The time now is 06:01 AM.


Powered by vBulletin® Version 3.8.4
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Content copyright © 2007-2010, the authors
Daemon image copyright ©1988, Marshall Kirk McKusick