Saturday, February 25, 2012

Concerning programming, What is character string?

Is it one thing or are they two different types of non-numeric data? and also what about boolean what is it?

ThanksConcerning programming, What is character string?
A character is only one character such as 'A'

A string can be one character or 1000 such as "Hello"

Boolean is a variable that is either true or false.Concerning programming, What is character string?
Boolean = True or False. That simple. Usually used to do a series of checks, then if whether the overall result is what is desired, sets the variable to True, and if it isn't, sets it to False, so the rest of the program can respond appropriately. An example of this is going over every item in an array or list, and doing the checks on each item individually, and if every item is true (or if at least one is true, depends on the reason for the check and what you're checking for) then you continue doing what you intended to do with the data, otherwise you back out and use what ever the back up plan was.



Character String. A string is a collection of character variables put into an array. Each character is a byte in Ascii (8 bits of data, total of 255 characters), or differing amounts for UTF text formats (some can be one byte, some characters can be 2 or 3 bytes). The string is combining many of these together to create a visible sentence, paragraph, page, etc.

No comments:

Post a Comment