answersLogoWhite

0

A rectangle might have a width, a height, a color, and a fill

pattern. C lets us organize these four items into one group called a

structure. Example

struct rectangle {

int width; /* Width of rectangle in pixels */

int height; /* Height of rectangle in pixels */

color_type color; /* Color of the rectangle */

fill_type fill; /* Fill pattern */

}; Another example suppose we want to record

the time a runner completes each lap of a four -lap race. We define a structure to

store the time:

struct time {

int hour; /* hour (24 hour clock ) */

int minute; /* 0-59 */

int second; /* 0-59 */

}; A rectangle might have a width, a height, a color, and a fill

pattern. C lets us organize these four items into one group called a

structure. Example

struct rectangle {

int width; /* Width of rectangle in pixels */

int height; /* Height of rectangle in pixels */

color_type color; /* Color of the rectangle */

fill_type fill; /* Fill pattern */

}; Another example suppose we want to record

the time a runner completes each lap of a four -lap race. We define a structure to

store the time:

struct time {

int hour; /* hour (24 hour clock ) */

int minute; /* 0-59 */

int second; /* 0-59 */

};

User Avatar

Wiki User

16y ago

What else can I help you with?

Related Questions

Is c programing a procedure oriented programing?

yes


Why you need C programming?

C- Programing is basically a programing language of a computer. It helps to create software programing language which is usefull in creating softwares & data base programes. C programing language is the first & basic programing language. Other programing languages are:- C, C++ & C# (latest).


What do you mean by c?

c is a programing language


Short note on structural programming and procedural programming?

There is no difference between procedural programing language & structure programing language.


What is statement in C programing?

One of the statements, obviously.


What are the examples of programing language?

c, c++, java, prolog, fortran, basic, ...


How do you perform programs on c programing language?

Using IDE environment


What are some examples of programming language?

The most well-known programming languages are C, C++, C#, CSS, HTML, Javascript, PHP, Pascal/Delphi, Prolog, Python, Ruby, Visual Basic, and Visual Basic .NET, java.


Is c an object oriented programing language?

C language is not a program, and it isn't an object-oriented language either.


Why c language is called c language?

C is descendent from another programing language called B which was at that time when 'C' was invented. That's why it derived its name as 'C' successive to 'B'.


What are programming language that produced c?

C is a programming language. Example of C or C++ Programing would be the following: add matrices, get ip address, and read files.


List some programing languages?

* Java * C, C++ * Basic * COBOL * Fortran * Pascal * .Net * Visual Basic * etc...