Q:

i don't understand what is %[^\n]

I saw a program to input a string without using %s, %c format specifiers and gets, fgets functions even. Can explain each and every line of this code? s1 is character pointer. But pointer takes address. What is this ""\45\133\136\12\135\163". We have another character pointer *s2 ok. Now scanf takes two addresses i understood this but without % specifier. How? And then this printf(s2) statement.  
I read ANSI C book by K&R but it wasn't there. Bible of C doesn't have this concept. How come? Please tell me where to read more about %[^\n]. Where else i can use this concept.
int main()
{
char *s1 = "\45\133\136\12\135\163", *s2;
printf("Enter the string: "); 
scanf(s1,s2);
printf(s2);
return 0;
}

A:

Your code is merely obfuscated and is exactly equivalent to:
int main()
{
  char *s1 = "%[^\n]s", *s2;
  printf("Enter the string: "); 
  scanf(s1, s2);
  printf(s2);
  return 0;
}

The obfuscated string literal "\45\133\136\12\135\163" is using octal character representation. For example, '\12' is character code 10, LF, same as '\n'.
Let's decode the format string:

% - introduces a conversion
[ - starts a match of a nonempty sequence of characters from the specified set
^ - indicates that the following characters are to be excluded from the set
\n - the set excludes the newline (character code 10)
] - ends the set specification and the conversion.
s - matches a literal s.

Thus, the scanf will input any non-empty string that doesn't contain a newline, as long as it's followed by s.  The s is essentially unnecessary and likely a bug.
BUGS
It should be noted that the code has three (or most likely four) bugs and won't work as shown. Someone should be focusing on obfuscating correct code to start with.

scanf reads into a buffer pointed-to by an uninitialized pointer. If it works, it's by pure chance. It should be reading into an allocated buffer instead.
The use of a string conversion in scanf without the length is also a bug.
The s at the end of the format string is likely invalid, unless the intent was to match a literal s at the end of the string. It is a bug in the light of:

It being invalid (if allowed) to specify infinite length string conversions.
It maching if the string conversion matches full length.

printf(s2), where s2 is entered by the user, is a bug too.

I must stress that #2 and #4 are not a "security hole" or any such thing, just bugs plain and simple. If any textbook shows such code, the authors should be dragged over hot coals. I mean it. It will work sometimes, some other times it will crash, yet another time it will format your hard drive.
The code should read something like:
int main()
{
  char *s1 = "%255[^\n]";
  char s2[256];
  printf("Enter the string: "); 
  scanf(s1, s2);
  printf("%s\n", s2);
  return 0;
}

