Search This Blog

UI/UX Design | Web Development | Mobile Application Development

Whether you need UI/ UX design, web development services, or mobile app development services, Qaabil Digitals will be more than happy to help you. We work with top software developers, designers, and project managers. We tailor our services to suit your exact needs. We closely look at your company, listen to your story, and bring about the best ideas and solutions that can help you drive solid results. We don’t just produce work that works. We produce work that matters. Get a quote now Or Talk to us

Saturday 25 June 2011

What is type casting?


Type casting:
            If we want to store an integer value in a byte or short type variable. What we will do? When we need to store a large value in a small data type variable we use type casting. In type casting we explicitly make a value narrow so that it will fit into the targeted variable. 

General syntax:
                  Two incompatible/different data types can be converted into same. Its general syntax is
  • (target-type) value;
Here, target-type is the casting type, that data type in which your given value will be converted and value can be any variable or constant value.

Click here to see a program of type casting

No comments:

Post a Comment

Share