Answer:
showProduct(int,double)
for example: showProduct(10,10.5) is the correct answer even showProduct(10,10.0) is also correct but showProduct(10.0,10.5) or showProduct(10,10) or showProduct(10.0,10) are wrong calls.
Explanation:
The code is
- <em>public static void showProduct (int num1, double num2){</em>
- <em> int product;</em>
- <em> product = num1*(int)num2;</em>
- <em> System.out.println("The product is "+product);</em>
- <em> }</em>
showProduct is function which asks for two arguments whenever it is called, first one is integer and second one is of type double which is nothing but decimal point numbers. Generally, in programming languages, 10 is treated as integer but 10.0 is treated as decimal point number, but in real life they are same.
If showProduct( 10,10.0) is called the output will be 'The product is 100'.
Strange fact is that, if you enter showProduct(10,10.5) the output will remain same as 'The product is 100'. This happens because in the 3rd line of code,which is <em>product=num1*(int)num2</em>, (int) is placed before num2 which makes num2 as of type integer, which means whatever the value of num2 two is given, numbers after decimal is erased and only the integer part is used there.
This is necessary in JAVA and many other programming languages as you <u>cannot</u><u> multiply two different datatypes</u> (here one is int and another is double). Either both of them should be of type int or both should be of type double.
A virus or malware appearing/pretending to be a legitimate program is called a Trojan.
In the case above, Ruben should consider the printing option below:
- Offset litho printing.
- Digital Printing.
- Screen printing.
<h3>What is the best printing type for books?</h3>
The use of digital printing is known to be the best in the case with Ruben. It is said to be much more economical in terms of shorter print runs.
Note that Digital printing do have fast turnaround time and as such it is better for books.
Therefore, In the case above, Ruben should consider the printing option below:
- Offset litho printing.
- Digital Printing.
- Screen printing.
Learn more about printing from
brainly.com/question/145385
#SPJ1
Answer: Local Area Network (LAN)
Explanation:
A Local Area Network (LAN) is a computer network that interconnects computers within a limited physical area such as a residence, school, laboratory, university campus or office building.
An example of LAN network is "Phone, Computer and TV connected to a single network (such as a Home Network) via Cables, Wifi, Bluetooth or Hotspot". When the devices are interconnected or connected to a LAN, it becomes accessible between each other.
A simplest example of a LAN Device is a <em>Home Router.</em>
The program is an illustration of functions.
<h3>What are functions?</h3>
Functions are set of program statements that are executed when called or evoked.
<h3>The main program</h3>
The function written in Python, where comments are used to explain each line of the program is as follows:
#This defines the function
def posodd_number_filter(num):
#This checks if the function is odd and positive
if num >0 and num%2 ==1:
#If yes, this returns Accepted
return "Accepted"
#If no, this returns Rejected
return "Rejected"
Read more about functions at:
brainly.com/question/14284563