answersLogoWhite

0

What is return a void data type?

Updated: 8/10/2023
User Avatar

Wiki User

11y ago

Best Answer

#include<stdio.h>

int main(){

int num,i,f,r,sum=0,temp;

printf("Enter a number: ");

scanf("%d",&num);

temp=num;

while(num){

i=1,f=1;

r=num%10;

while(i<=r){

f=f*i;

i++;

}

sum=sum+f;

num=num/10;

}

if(sum==temp)

printf("%d is a strong number",temp);

else

printf("%d is not a strong number",temp);

return 0;

}

User Avatar

Wiki User

11y ago
This answer is:
User Avatar
More answers
User Avatar

Wiki User

11y ago

In the C language and derived languages (such as C++ and Java), '''void''' as a "return value" is used to specify that a function returns nothing. "Void", in English, means "empty".

This answer is:
User Avatar

Add your answer:

Earn +20 pts
Q: What is return a void data type?
Write your answer...
Submit
Still have questions?
magnify glass
imp
Continue Learning about Engineering

Why do you use a void pointer in a programme?

void is type of pointer that usually means that you can make it point to any data type. When you make a pointer point to somewhere its data type should match with the place where you want it to point. When you dont know the data type where it will point to then you can declare a void pointer and make it point to the data type it want.


What is returntype?

A return type describes the type of data which is returned by a call to a method. They keyword void is used to describe a method which does not return any data.


Is 'void' a data type in java?

No. The void keyword is used to signify that a method will not return any objects. For example, if you type in "double", you'll need a return statement that has a double. So "void" means that there will be nothing returned.


Is void a data type in c?

what is void data type Void is an empty data type normally used as a return type in C/C++, C#, Java functions/methods to declare that no value will be return by the function. The another use of void is to declare the pointer in C/C++ whe It is not sure that what data type will be addressed by the pointer. eg: void *p; Here p can hold the address of int or float or char or long int or double.


Application of void data type in c plus plus programming language?

The voiddata type is used when a function doesn't return any value, and/or when it has no parameters at all. Pointer type 'void *' is a generic pointer.A void pointer is used when it needs to be assigned to different data types later on in a program. Since it avoids type checking, void pointers should be used with care.

Related questions

Why do you use a void pointer in a programme?

void is type of pointer that usually means that you can make it point to any data type. When you make a pointer point to somewhere its data type should match with the place where you want it to point. When you dont know the data type where it will point to then you can declare a void pointer and make it point to the data type it want.


What is returntype?

A return type describes the type of data which is returned by a call to a method. They keyword void is used to describe a method which does not return any data.


Is 'void' a data type in java?

No. The void keyword is used to signify that a method will not return any objects. For example, if you type in "double", you'll need a return statement that has a double. So "void" means that there will be nothing returned.


Is void a data type in c?

what is void data type Void is an empty data type normally used as a return type in C/C++, C#, Java functions/methods to declare that no value will be return by the function. The another use of void is to declare the pointer in C/C++ whe It is not sure that what data type will be addressed by the pointer. eg: void *p; Here p can hold the address of int or float or char or long int or double.


What use of void data type in c plus plus?

doesn't return the value.


Application of void data type in c plus plus programming language?

The voiddata type is used when a function doesn't return any value, and/or when it has no parameters at all. Pointer type 'void *' is a generic pointer.A void pointer is used when it needs to be assigned to different data types later on in a program. Since it avoids type checking, void pointers should be used with care.


Why use void in main of java?

No. void is not a data type. It is mandatory for all java methods to return something and if it is not going to return anything, we have to mark the method with a "void" return type to let the JVM know that it must not expect anything from the method.


What are the three uses of void data types?

The void type has only one purpose: to specify the return type of a function that has no return value. In this case void simply means no type. The only other usage is when used as a pointer to void (void*), which simply means a pointer type that can refer to any type of object. If the pointer is non-null, it must be cast to a specific type before it can be dereferenced.


What TYPES of return values are allowed?

Apart from basic Data types (int , char , float and double ) you can even return Class Objects.Nearly any type of Data can be returned by a function including pointers to void data type.


Why void is preemptive data type?

void isn't an actual data-type, preemptive(?) or otherwise.


Can you take return type in void?

a void has no return statement. If that is what ur asking


What is the return type of calloc function?

the return type is void