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
oee [108]
3 years ago
11

Write a boolean method that checks whether a given positive integer n is a perfect square. Use Math’s sqrt and round methods to

find the square root of n, round it, then square the result and compare with n. Do not use any iterations or recursion.
Computers and Technology
1 answer:
svetoff [14.1K]3 years ago
5 0
In java...

public boolean checkSquare(int n){

int actualNumber = n;
int squareRoot = (int)Math.sqrt(n);
int squaredNumber = Math.pow(squareRoot,2);

if(squaredNumber==actualNumber){
return true;
} else {
return false;
}

}
You might be interested in
Disk ________ realigns separated data so that related file pieces are unified.
PilotLPTM [1.2K]
Disk defragmentation realigns separated data so that related file pieces are unified. <span> Defragmentation is is the process of consolidating fragmented files on the user's hard drive.</span>This Microsoft Windows utility includes <span>rearranging the fragments and restoring them into fewer fragments or into the whole file.
</span>
4 0
2 years ago
Guys I need help I cant download anything in the app store I restarted my phone and I know it's not the space on my phone I have
Simora [160]

Can you give me further explanation? For example, how is your phone not letting you download things? What model of a phone is it? what update is it on? and to what extent can you download something?

4 0
2 years ago
In a stack data structure, the following items are inserted in the following order: Bob, Alice, Charlie, Eve, Zebra. Then an ite
const2013 [10]

Answer:

Zebra.

Explanation:

Stack is LIFO, so Zebra is added in the last so it will be removed first.

6 0
2 years ago
A technician has just installed a new SOHO router for several users to share an Internet connection. He received a call that, wh
Katena32 [7]

Answer:

The technician needs to adjust the quality of service tool.

Explanation:

Quality of Service (QoS) tool is a feature in  routers and switches which prioritizes traffic so that more important traffic can pass first which results in an improved performance for critical network traffic.

So whenever a complaint is made to the technician that a particular user is using much of the browsing speed which is slowing down the browsing speed of others,  The technician needs to adjust the Quality of Service tool of the router that allows the router to share the bandwith among users.

7 0
2 years ago
Which part of the cerebrum is associated with hearing and memory?
Brut [27]
I'm pretty sure it's the frontal lobe
4 0
3 years ago
Read 2 more answers
Other questions:
  • Social networking sites like Office Online, PayPal, and Dropbox are used to develop social and business contacts.
    6·2 answers
  • Find a, b, and c<br> A a=4 square root of 6 b= 8 square root of 2 ; c= 4 square root of 2
    12·1 answer
  • âwhat two log files are used by older versions of unix and newer version of linux to store log information
    10·2 answers
  • When saving a memo you created in Word, which one of the following extensions is automatically assigned to the document?
    13·1 answer
  • I have a summary to write for my robotics class but it is way too hard and i have a bery less time. If you can help me it would
    7·1 answer
  • The simplest element that exists is only one proton and one electron. It is what stars are made of. It's symbol is "H". What is
    9·1 answer
  • Describe the scope of the variables in this code.
    8·2 answers
  • A period in which unemployment is low, business produces many goods and services, and wages are good is called ______.
    8·1 answer
  • Briefly describe the traditional definition of the digital divide. What is it and who is affected, positively and adversely? How
    15·1 answer
  • Sistem komponen mekanikal yang terdapat pada sebuah basikal?​
    13·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!