Friday, October 25, 2019

C Language Basics

In this tutorial let's learn about basics of C programming language. Theory and practical both play key role in the learning process.
                

Programs/Applications need inputs to produce output.
  • char 1 - a single character.
  • int 2 or 4 - integer: a whole number.
  • float 4 - floating point value: ie a number with a fractional part. 3.14
  • double 8 - a double-precision floating point value. 5678.899999
  • void - Valueless.
Derived Data Types:
  • Arrays
  • Pointers
  • Structures
  • Enumeration

Escape Sequences in C:

Escape Sequence   Meaning
            \t                 Horizontal Tab
            \n               New line
            \'                Single quote
            \"               Double quote
            \?               Question mark
            \\                Backslash

Keywords in C 

Meaning is already defined by Compiler

auto        double   struct       int
break      long       else          switch
char        enum     register    typedef
case        extern    return union
const       for         short       unsigned
continue  float      signed     void
goto         default  sizeof     volatile
do            if           static      while

Wrong way of usage:

int if;  //wrong

Note: Keywords cannot be used for creating variable and function names.

Reading Values from Keyboard in C

  • We use scan statement to take input from the keyboard. We can take one or multiple inputs using one scanf statement. 

Rules for Creating Variables:

  • Should start with alphabet or an underscore only. int abc; int ABC;
  • No spaces allowed.
  • Only _(Underscore is allowed to use).
  • keywords cannot be used as variable names.
  • Case sensitive.

scanf in C 


Explanation: 
scanf(“format string”, argument list);

Example:
int a=2;

int a;
scanf("%d",&a);

int a,b;
scanf("%d%d",&a,&b);

"For Loop" in C: 

"For Loop" in C: Initially it looks difficult, but after a while it will be the one of the common thing that you use in every program or application.
Let’s see how and why in my words!!!!!
To print my name the simple code is here:
  #include 
  int main()
  {
    printf("Kirthi");
    return 0;
  }


Output: Kirthi


Let’s say if I want to print my name(Kirthi) for 100 times, then I should write printf statement 100 times.


Or I should mention my name 100 times in the printf statement.
To simplify this, we need to use of “for loop”.


  #include<stdio.h> 
  int main()
  {
    for(int i=1;i<=100;i++)
    {
      printf("Kirthi \n");
    }
  return 0;
}
Output:
Kirthi
Kirthi
.
.
Kirthi(100 th time).


In above example for loop iterates 100 times because of the condition that we've specified. To make program smaller, to reduce lines of code for loop is used.

Tips For Improvement!

How to overcome Laziness?

It is a state where you cannot think⊂ and do as per your capability. Laziness causes mental and physical disorder if you won't react to it initially. Though it is not a serious disease which can be treated but it requires motivation to overcome. Focus on important things that you must accomplish. Organize your time properly in a day wise or weekly. Understand what you're thinking inside and change the way you think. Try to set smaller goals initially and work to achieve it. Consider this is the right time to break the silence inside you and think you can be a successful. Action is required for all your motivations in you. Obviously every step taken is really a beneficial for you.

  • Its directly not a problem or disease.
  • Requires motivation.
  • Focus on important things.
  • Organize your day properly.
  • Analyse your self-talk.
  • Break the silence, start thinking that you can do.
  • Every step taken is beneficial for you.

How to be active every moment?

Think present and live in reality, do not dig into past unnecessarily. The moment's which went wrong earlier would come to your head the moment you're alone and upset, so be alert control your emotions keep yourself calm and focus on something else. Listening to music would keep you active, prepare a playlist a role it whenever you feel your down.

How to say no without hesitation?

Be strong and say confidently that you oppose certain things without any second thought. Try to explain points that you think are correct in your perspective. Hence time will play key role so be sure of yourself. If you hesitate then you've certainly invited problems and you have to face the consequences of it.

How to improve yourself?

  • Be early at work
  • Wear formals
  • Look  cool
  • Set your goal
  • Be a performer
  • Wish your team mates with smile
  • Make right decisions
  • Think before you speak anything
  • Don't involve in unnecessary discussions
  • Read and respond to emails on regularly intervals
  • Learn more

How you should deal with your Manager?


  • Do your job(Implement accurately the responsibility that assigned to you).
  • Communicate all the important/key information by Mail, becomes formal.
  • Always speak in formal language(official), avoid speaking in regional language.
  • If you feel your Manager is arguing on irrelevant issues by holding grudges, just ignore them.
  • Do not disclose it with other team members whatever is happening in between you and your manager.
  • Pick right time to report it to higher authorities with right reasons possibly with proofs for what you point out.

Do not take resignation decision until you have an excellent offer in your hand. The end is not the solution for problems, any team any company would have issues, finding out the ways to overcome is important rather quit.

What role does your health play in your career?

A famous saying "Health is Wealth" is what everyone have to recollect at least once in a day. If you're not doing good then you can't be creative, that's it. Eat on time, eat good food, treat your body well, replacement or repair to any organ is painful and extremely costlier, finding the way to overcome from any health disorder is highly difficult. The first preventive step is to avoid eating foods that has too much fat in it especially the junk one's. Start your day with a couple of glass of water, prefer light warm, ensure you drink a minimum of two to three liters of water in a day. Water flushes away most of the junk that exists in your stomach and keeps it as much as calm as possible. On the other hand too much water can upset your stomach and you may have to go to wash room for a couple of times, so have it in limits. Eat fruits, fruit salads, and have fruits juices as much as you can which is considered to be extremely great diet.

What is the difference between function and method?

First let's understand function. In C programming language, we use functions which contains a piece of code and every function must have a unique name with which it should be called or invoked.

Example:
#include<stdio.h>
int sum();
void main()
{
  int z;
  z = sum();
  printf("z = %d",z);
}
int sum()
{
 int a=5, b=9, c;
 return c=a+b;
}

In Object-Oriented Programming languages we use objects to invoke methods.
Syntax: Object.Method();

Note: In C langugae we don't have concept of class and object.

Function does not belong to any object or class.
Method belongs to a class.

All methods are functions, but not all functions are methods. 

Wednesday, May 29, 2019

Best Stocks to buy in June 2019

On 20th May'19, all Stocks on both the indices NSE and BSE gained profits after exit polls revealed that NDA would attain power once again. The good news is that, there a few gem stocks that are under performing because of bad quarter results or some other reason. Now, we would discuss on what stock you can bet in June'19 which could give you atleast 10 to 40 percent profit.

Hero Moto Corp: It was seen trading around 2750/- levels on NSE at the end of May'19. This is the one of the strongest stock in Nifty Auto segment which could raise to 3500/- levels in a couple of quarters or by the end of 2019. One could add more quantities if it goes below 2500/- ie add on every fall. Hero is fundamentally a very strong company and their products does very well in Indian markets.

TCS: Tata Consultancy Services is fundamentally strong compnay and got an excellent potential to grow up by atleast 30 to 40 percent probaly in a year. It was trading around 2100/- levels on NSE by end of the May'19 and hopefully it may trade over 2500/- levels. This IT gaint is growing quarter by quarter and making itself one of the most stronger companies in NIFTY 50 itself.

Reliance Industries Limited: Got wide range of business in the market and in addition to this it got friendly government at the center which makes this legend stand tallest in terms of economically and fundamentally. Strongest company seen trading at 1300/- levels on NSE and would certainly expected to trade over 1600/- leves in near future and might also reach 1800/- by March'20.

DMart: Avenue Super Markets or DMart is doing excellent business and opening as many branches as possible in the cities where they're present in, its business spreading throughout the nation succesfully. DMart have got great offers on retail products especially for middle class people across the country. It is trading at 1300/- leves on NSE and expected to touch 1800/- leves probably by an year.

Thursday, April 11, 2019

Seventeen Lok Sabha Seats in Telangana

Seats won party wise: TRS: 9 Seats. BJP: 4 Seats. Congress: 3 Seats. AIMIM: 1 Seat.
  1. Chevella (TRS)
  2. Khammam (TRS)
  3. Mahbubabad (TRS)
  4. Mahbubnagar (TRS)
  5. Medak  (TRS)
  6. NagarKarnool (TRS) 
  7. Peddapalli (TRS)
  8. Warngal (TRS)
  9. Zaheerabad (TRS)
  10. Malkajgiri (Congress)
  11. Bhongir (Congress)
  12. Nalgonda (Congress)
  13. Adilabad (BJP)
  14. Secunderabad (BJP)
  15. Nizamabad (BJP)
  16. Karimnagar (BJP)
  17. Hyderabad(AIMIM)
General elections for seventeen seats in Telangana has been conducted on 11th April'19 in the 1st phase of General election 2019. Results declared on 23rd May'19, TRS the party in power at the state won 9 seats while congress won 3 and surprisingly 4 seats won by BJP.

TRS won from Chevella, Khammam, Mahbubabad, Mahbubnagar, Medak, Nagarkarnool, Peddapalli, Warangal, and Zaheerabad.

Congress won from Malkajgiri, Bhongir, and Nalgonda.

BJP won from Karimnagar, Nizamabad, Secunderabad, and Adilabad.

AIMIM won from Hyderabad.

This election was quite disappointing for TRS as it won only 9 out 16, where the party is expected to clean sweep all the 16. Another big set back is Kavitha, daughter for CM KCR lost to D Aravind of BJP. Interesting point is D Aravinds father is Rajya Sabha member belonging to TRS party itself. 

Tuesday, November 13, 2018

Use this Free Sounds Effects without worrying about Licence issues!


Using sounds found over internet can be illegal to use in your projects. Here is one of the best source where you can use the clips free to use without worrying about copyright or licence issues. All the sounds are crystal clear which doesn't really need any sort of editing to them. Here is the link: https://www.freesoundeffects.com/free-sounds/scary-and-horror-10085.

Audio files are available in both MP3 and WAV formats. You could download instantly without any sort of signup or register. There is a play button left to if where you can listen to the preview. Categories have been mention on the left side of the website, click on your choice and scroll through the page, even you could navigate between various result pages.

The best sounds I've felt on this site is, the Scary/Horror, Vehicles, Knocking the door, Ocean waves, Fire crackers, Fire engine, Foot steps, Car door, Old telephone ringing, etc. All are not for free, some sounds are paid on this site, there is a section by name "Pro Sound Effects", which are paid. If you really feel they would help you then go and buy otherwise keep trying for free content over the internet.  

Friday, October 12, 2018

How Google Pay is better than other Wallets!

Google Pay is a digital wallet and online payment system developed by Google. It is primarily used to transfer money between users via UPI. Users need to download, install, register themselves on Google Pay. For UPI transactions, you need to link this Google Pay account with one of your saving bank account, the mobile number linked to bank account and Google Pay registered number should be one in the same. You could set password to open the app and a separate password for all the UPI transactions.

After registration, users can transfer money, send messages to their contacts. You could also earn 51/- on successful referral and it will be 151/- in your wallet if your referral does UPI transaction, they appear in the bottom with name "INVITE A FRIEND". Apart from this you would scratch cards, upon swiping them you get cash back which will be directly credited in to your bank account. Find this in the Rewards of the Promotions section, this section also shows you with the current offers.

Google Pay app shows list of people with whom you've already had successful transactions. You can even link your mobile for making recharges with this app. You can check your bank account balance anytime by clicking on the CHECK BALANCE option. If you wan to check the list of transactions any point of time then click on the "TEZ MODE TRANSACTION", which lists you with all the credits and debits from the begging of time.

On the other hand it is quite dangerous because it can he hacked by anyone in and around as. The app password(4 digit) and the UPI PIN(6 digit) both are numeric and are easy for someone to trace. One must be very careful because all the money from bank account can be stolen in a less than a minute.