ONLINE LEARNING

c language

It's all about self learning.

C-DATA TYPES-II

In this session,We will Discuss about rest of data types.
4 July, 2016     
VOID TYPE:The void type, in several programming languages derived from C is the type for the result of a function that returns normally, but does not provide a result value to its caller. Usually such functions are called for their side effects, such as performing some task or writing to their output parameters.

What is the purpose of void type?
  • the void keyword specifies that the function does not return a value
  • void specifies that the function takes no parameters
  • void specifies that the pointer is "universal."

Program:

#include
void message();
int main()
{
message();
return(0);
}
void message()
{

printf("sourabh_gupta");
}

OUTPUT: Sourabh_gupta

 
.

Get solution for your websites

logo