1answer.
Ask question
Login Signup
Ask question
All categories
  • English
  • Mathematics
  • Social Studies
  • Business
  • History
  • Health
  • Geography
  • Biology
  • Physics
  • Chemistry
  • Computers and Technology
  • Arts
  • World Languages
  • Spanish
  • French
  • German
  • Advanced Placement (AP)
  • SAT
  • Medicine
  • Law
  • Engineering
andrew-mc [135]
3 years ago
8

How to call a void method with no parameters IN JAVA?

Computers and Technology
1 answer:
natka813 [3]3 years ago
6 0

Explanation:

SanfoundryMenu

Java Program to Illustrate a Method without Parameters and Without Return Type

« PrevNext »

This is a Java Program to Illustrate a Method without Parameters and Without Return Type.

We have made the method to calculate area. We call this method from main method and then enter the radius of the circle as input. Now we calculate area and print the output.

Here is the source code of the Java Program to Illustrate a Method without Parameters and Without Return Type. The Java program is successfully compiled and run on a Windows system. The program output is also shown below

You might be interested in
Write a program named ArrayDemo that stores an array of 10 integers. (Note that the array is created for you and does not need t
romanna [79]

Answer:

Hi Zoom! Good question. This is particularly useful for learning sorting functions in arrays and user input handling as well. Please find the implementation below.

Explanation:

I have implemented the code in Python 2+. You can save the below code into a file called ArrayDemo.py and then run it from the command line with the command "python ArrayDemo.py". I have declared the demo_array in the code to an array of 10 unsorted integer values to test this. You can change the code if needed to have this array input by user as well and it should work fine.

Note: if you're using Python 3+ then you'll need to change the "raw_input" in the code to just "input" to make it work.

ArrayDemo.py

demo_array = [2,1,3,4,5,7,6,8,10,9]

option = 0

while (option != 4):

 option = raw_input("Enter 1 to view list in ascending order, 2 to view list in descending order, 3 to choose specific poisition to view, 4 to quit the application: ")

 try:

   option = int(option)

   if option == 1:

     sort_by = 'asc'

     print(sorted(demo_array, reverse=False))

   elif option == 2:

     sort_by = 'desc'

     print(sorted(demo_array, reverse=True))

   elif option == 3:

     position = raw_input("Enter specific position to view (0-9): ")

     try:

       position = int(position)

       if position < 0 or position > 9:

         print("Position does not exist")

       else:

         print(demo_array[position])

     except ValueError:

       print("Position does not exist!")

   elif option == 4:

     break

   else:

     break

 except ValueError:

   print("Invalid input!")

5 0
3 years ago
What symbol is used for an assignment statement in a flowchart?
Annette [7]

Answer:

processing

Explanation:

The flow chart is a diagram that shows the activity of the program, peoples or things.

Flowchart symbol and meaning in the options:

1. Processing: it is a rectangular shape block which is used for variable declaration or assignment.

2. I/0: it is a parallelogram in shape which is used for input or output.

3. Parallelogram: it is used for input or output.

4. diamond: it is used for decisions or conditions.

Therefore, the correct option is a. Processing is the one that is used for the assignment statement.

3 0
4 years ago
How to trigger watchers on initialization in vue.js ?
ale4655 [162]

Answer:

variable when the component is mounted. This triggers the watchers which then triggers an emit i have in the watcher. I do not want the emit to happen when the variable is only being initialized. The variable is from the data section of the vue component.

3 0
2 years ago
Which button would you use to quickly add addresses to a mail merge envelope?
Jet001 [13]

The answer to your question is,

C. Address Block

-Mabel <3

5 0
4 years ago
You have a small network at home that is connected to the internet. On your home network, you have a server with the IP address
oksian1 [2.3K]

Answer:

Answer C

Explanation:

Static NAT creates a fixed translation of private addresses to public addresses. The main difference between dynamic NAT and static NAT is that static NAT allows a remote host to initiate a connection to a translated host if an access list exists that allows it, while dynamic NAT does not.

5 0
3 years ago
Other questions:
  • A(n) __________ program translates a high-level language program into a separate machine language program.
    8·1 answer
  • In which of these places might you be most likely to find a peer-to-peer network? On the Internet In a hospital In a home In a l
    5·2 answers
  • What date does GTA 6 come out<br> A. 2020<br> B. 2019<br> C. 2021<br> D. 2022
    10·2 answers
  • Need help . business and technology
    11·1 answer
  • Which of the following would you not see on a windows 10 start menu?
    6·1 answer
  • What are the 3 examples of numeral systems
    5·1 answer
  • PLS HELP For this activity, you can use the audio recorder on your cell phone or a digital camera to record the following sounds
    14·1 answer
  • IF YOU LOVE GOD HELP ME......What should be covered in the conclusion of a presentation?
    11·2 answers
  • What are the two different types of dns requests?
    5·2 answers
  • ____ takes care of the transport between machines. but it is unreliable, and there is no guarantee that any given packet will ar
    12·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!