Google+

Sunday, July 25, 2010

A Complete Guide to Google Special Search – How to Use Google A Lot More Creatively (Part I)



Google is no doubt the most popular search engine till date. Millions of people across the globe use it everyday to search for content, pictures, blogs and everything else. The reason of the huge popularity of Google is because the results are so relevant and match closely with what the user is searching for.

Apart from regular search queries, do you know that you can use the Google search engine in a variety of creative ways? You can use Google to know the sunrise and sunset timings, convert currency amounts, perform local searches, find movie show times and so on. These type of Google search, better known as Google special search requires the user to type a specific query and add an attribute to the query.

A very good example of a special Google search is knowing the time of a particular city. I live in India and want to know what time is it in London, UK. To perform this Google special search, I will have to type the exact query as “What time is it” and supply the parameter as “London”





What’s interesting to note is that these Google searches depend upon your geographic location (in some occasions) and the results are displayed accordingly.

In this article, we look into some special Google searches which can be used in a more creative way to know important things you have always wanted:
Know the Weather of a Any City Using Google

To know the weather conditions of any city, go to Google.com and enter the name of the city in the search box. Then type the state and the country of the city, as shown in the following example:



Not only will Google display the current average temperature of your city, but you can also see the weather pattern for the last week. Additional details like humidity and wind speed are also shown in the same page and you can add the result to your iGoogle home page using the link “Add to iGoogle”.

Know the Time of Any City Using Google

Similarly you can also know the present time of any part of the world using a simple Google search. Just type time in the Google search box followed by the name of the city or country as shown in the following example:




Wednesday, July 14, 2010

Bit Wise in any programming language

Bit wise operator in C,.NET,JAVA,C++

C Bitwise Operators
The bitwise operators perform bitwise-AND (&), bitwise-exclusive-OR (^), and bitwise-inclusive-OR (|) operations.

Syntax:-

AND-expression:
equality-expression

AND-expression & equality-expression

exclusive-OR-expression:
AND-expression

exclusive-OR-expression ^ AND-expression

inclusive-OR-expression:
exclusive-OR-expression

inclusive-OR-expression | exclusive-OR-expression

The operands of bitwise operators must have integral types, but their types can be different. These operators perform the usual arithmetic conversions; the type of the result is the type of the operands after conversion.



Operator Description

  • &

The bitwise-AND operator compares each bit of its first operand to the corresponding bit of its second operand. If both bits are 1, the corresponding result bit is set to 1. Otherwise, the corresponding result bit is set to 0.
  • ^

The bitwise-exclusive-OR operator compares each bit of its first operand to the corresponding bit of its second operand. If one bit is 0 and the other bit is 1, the corresponding result bit is set to 1. Otherwise, the corresponding result bit is set to 0.

  • |

The bitwise-inclusive-OR operator compares each bit of its first operand to the corresponding bit of its second operand. If either bit is 1, the corresponding result bit is set to 1. Otherwise, the corresponding result bit is set to 0.

Examples
These declarations are used for the following three examples:


short i = 0xAB00;
short j = 0xABCD;
short n;

n = i & j;
The result assigned to n in this first example is the same as i (0xAB00 hexadecimal).


n = i | j;

n = i ^ j;
The bitwise-inclusive OR in the second example results in the value 0xABCD (hexadecimal), while the bitwise-exclusive OR in the third example produces 0xCD (hexadecimal).

Microsoft Specific

The results of bitwise operation on signed integers is implementation-defined according to the ANSI C standard. For the Microsoft C compiler, bitwise operations on signed integers work the same as bitwise operations on unsigned integers. For example, -16 & 99 can be expressed in binary as

11111111 11110000
& 00000000 01100011
_________________
00000000 01100000

The result of the bitwise AND is 96 decimal.

Sunday, July 4, 2010

SQL Statements

SQL Statements

Oracle SQL complies with industry-accepted standards. Oracle Corporation ensures future
compliance with evolving standards by actively involving key personnel in SQL standards
committees. Industry-accepted committees are the American National Standards Institute (ANSI)and the International Standards Organization (ISO). Both ANSI and ISO have accepted SQL as the standard language for relational databases.

Statement Description
  • SELECT Retrieves data from the database
  • INSERT,UPDATE,DELETE,MERGE
Enters new rows, changes existing rows, and removes unwanted rows
from tables in the database, respectively. Collectively known as data
manipulation language (DML).
  • CREATE,ALTER,DROP,RENAME,TRUNCATE
Sets up, changes, and removes data structures from tables. Collectively
known as data definition language (DDL).
  • COMMIT,ROLLBACK,SAVEPOINT
Manages the changes made by DML statements. Changes to the data can
be grouped together into logical transactions.
  • GRANT,REVOKE
Gives or removes access rights to both the Oracle database and the
structures within it. Collectively known as data control language
(DCL).

Saturday, July 3, 2010

Pascal Triangle in C


Pascal triangle is a like a simple diagram that contain some rules and logic. It's figure are shown above. 

  • first element of all row is 1.
  • last element of all row is same as starting element.
  • second last element of all row is same as second element and so on.
  • a[2,1]=a[1,0]+a[1,1]; for second row second element.
  • a[3,1]=a[2,0]+a[2,1]; for third row second element,a[3,2]=a[2,1]+a[2,2]; for third row third element and so on.

If you want it's program in any language then reply me.