answersLogoWhite

0

Why use the void display()?

Updated: 8/11/2023
User Avatar

Wiki User

7y ago

Best Answer

void display is the function name in which we want to perform some task or it might be to display something. But it has got its residence in the main() function that means that function's inputs are being supplied from the main(). void doesn't return anything so function call is made in main() which doesn't return anything back to it.

User Avatar

Wiki User

13y ago
This answer is:
User Avatar

Add your answer:

Earn +20 pts
Q: Why use the void display()?
Write your answer...
Submit
Still have questions?
magnify glass
imp
Continue Learning about Engineering

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.


C program pointers to pointers examples?

Pointer to Pointer is a double pointer, denoted by (**). Pointer stores the address of the variable and pointer to pointer stores the address of a pointer variable and syntax can be given as int **ptr2ptr;


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.


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.


Write a program that read and display double number?

class simple { public static void main(String[] args){System.out.println(new java.util.Scanner(System.in).nextDouble());} }

Related questions

How do you display stars in c plus plus using the if else structure and a for loop and you use void main?

It depends on what program you design really


How do you write a void function with one value parameter that will display the alphabetic character V on the screen.?

void myFunc(int parameter){cout


Is void better than dragon?

depends if your maxing void is better but id use d boots with void and never use the void weapon i personally prefer bandos but drag and void is welfare and good my runescape name is OpTiC Sam


Why you use viod in c?

It's void, and you use is for different purposes, like:a function doesn't have return value: void fun () ...a function doesn't have parameters: ... fun (void) ...generic pointe: void *ptr;r


How do you use void in a sentence?

I felt a great void when she left. When you make a mistake when writing a check, you should write "VOID" on it.


How do you create a class and declare a method in C?

class classname { public://access specifiers// { int a,b;//a and b are data members// void get() { printf("\n mouni no"); scanf("%d",&a); } void display() { printf("mouni no is",&a); } }; here void functions are methods


How do you use the word void in a sentence?

When her father died, it left a huge void in her heart. There was a void in the ground, making it impossible to cross on foot. He declared the will null and void.


How 2 display 10 no in programming?

to display 10 numbers in C language we can use the while loop.... #include<stdio.h> #include<conio.h> void main() { int n=0; while(n<=10) { printf("%d",n); //it will print the 10 numbers as output } getch(); }


Why you are using VOID in C programming?

You don't use 'VOID', but 'void'. It means different things, such as:- void as function type means no return value- void as function parameter means no parameters- 'void *' as pointer-types means generic pointer


How do you create program that display your name?

#include<stdio.h> #include<conio.h> void main() { clrscr(); printf("Your name here"); getch(); }


How do you display a message in C?

In C, the most common way to display a message is by using printf. The following code example will display Hello There! and start a new line.Code Example:#include int main(void) { printf("Hello There!\n"); return 0; }


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.