Linux Tips

Changing Linux root password
http://www.paulspoerry.com/2008/09/06/replace-linux-root-password/

Ways of saying ‘Hello! World’ : http://www.fitzrovian.com/hello.html

– sizeof (type) requires parenthese, while sizeof expression
does not.

– How to easily read a declaration from left to right:
transform function argument types from inside out first
move the base type to the end
add outer parentheses if there’s an initial *
change every (*…) to … ->
one -> for each *
move qualifiers, so * const becomes const ->

Example: const int *(**const x [])()

*(**const x [])() const int base type to end
(*(**const x [])()) const int add outer parens
(**const x [])() -> const int remove outer ()
x [] const -> -> () -> const int remove inner ()

array of constant pointers to pointers to functions
returning pointers to constant ints

– p + 1 == &p [1]

Advertisements

One thought on “Linux Tips

  1. >When you talked about sizeof, here is what I understand. sizeof is an operator and the parenthesis following sizeof does not denote function. Parenthesis is to evaluate the expression.In other words, parenthesis is not part of sizeof operator, but part of expression whose size is returned.This is similar to ‘return’ statement at end of any function. It may or may not have parenthesis after it.

Leave a Reply

Please log in using one of these methods to post your comment:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s