Question

In: Computer Science

What are some different types of data you would expect to manipulate, and how would you...

What are some different types of data you would expect to manipulate, and how would you represent them in a program?

Solutions

Expert Solution

Every Program comprises of 2 main artifacts - Data and operations. Data can be represented using Data Types . They can be depicted as characters, arrays, numbers, booleans and structures. Structures , however, are replaced with objects in Object oriented world.

Below are high level types of data that a programmer could manipulate :

Characters ('a', 'b', ... 'z', '$', '#', etc)

Arrays (a list of data (of a particular Data Type!))

Numbers, (e.g., -5, -60.34,80.54).

Booleans (true or false)

Structures (a collection referring to a single entity)

Objects (instance of a class in Object Oriented language)

Representations

--------------------

a) Characters :

symbol = '#';

degree = '%';

b) Arrays

names =["Tom","Harry","John"]

c)Numbers

averageTemperature = 35;

major = 18;

  

d)Booleans

isButtonClicked = true;

e)Structures

We create a employee structure with various datatypes within it

employee.name = 'Harry';

employee.age = 28;

employee.salary = 4500;

employee.isManager = false;


Related Solutions

Different types of cells have different types of integral membrane proteins. What would you expect to...
Different types of cells have different types of integral membrane proteins. What would you expect to reside in the plasma membrane of an epithelial cell that might be absent from that of an erythrocyte? How do such differences relate to the activities of these cells? explain d in etail and give reference. (15points)
How would you define a solution? What are different types of solutions?
How would you define a solution? What are different types of solutions?
What are the two types of research hypotheses? How are they different? How would you determine...
What are the two types of research hypotheses? How are they different? How would you determine which type you are testing? What is meant by “one-tailed” and “two-tailed” tests? Give an example of a research question for each.
How do you understand price discrimination and what are some different types? Do you have some...
How do you understand price discrimination and what are some different types? Do you have some personal examples and do you think it is fair for consumers? What are the marketers' motivations to exercise price discrimination?
How would you choose between the different types of architecture that would allow you to cover...
How would you choose between the different types of architecture that would allow you to cover for redundancy, common access, and service to remote offices?
What different characteristics would you expect to find in a bacterium that causes infection in/on: –Lungs?...
What different characteristics would you expect to find in a bacterium that causes infection in/on: –Lungs? –Small intestines? –Stomach? –Skin?
How would deletion of the Runx3 gene affect T cell's development? Would you expect different results...
How would deletion of the Runx3 gene affect T cell's development? Would you expect different results if you knocked out IL7 expression in thymic epithelial cells?
If a different chemical than phospholipids can form membranes, what characteristics would you expect it to...
If a different chemical than phospholipids can form membranes, what characteristics would you expect it to have to be an adequate basis for life? If such a chemical exists, consider the characteristics of the chemical, how it would interact with itself and molecules in its environment, and the ultimate structure of the membrane. Make a list of these characteristics.
How can companies manipulate data about their practice?
How can companies manipulate data about their practice?
Explain what is data and list the different types of data? List and explain the different...
Explain what is data and list the different types of data? List and explain the different methods to collect data.
ADVERTISEMENT
ADVERTISEMENT
ADVERTISEMENT