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
shutvik [7]
3 years ago
8

Hi I am Khine Mye and I want to ask you a question I don't know that is square root of 2 is 1.4 and how to get that 1.4 and plz

explain me step by step​
Computers and Technology
1 answer:
MrRissso [65]3 years ago
3 0

Divide the radicand into groups of two, starting

from the decimal point and going in either

direction. For rational radicands, add pairs of

zeroes to the right of the decimal point as

needed. If the number is irrational, you already

have an infinite sequence of pairs. Now that the

radicand is marked off in pairs, forget the

decimal point (except in the answer). Call each

new digit of the approximation D, and the

current best approximation of the square root R.

Find the largest integer whose square is less

than or equal to the leftmost group. Since

groups are at most two digits long, the integer

is one digit long: in this case, the leftmost group

is 2, so we begin with D = 1, R = 1.

2 -1 = 1, append the next pair of digits, giving

100.

Find the largest digit D such that D*(20*1+D) is

less than or equal to 100.

(HINT: estimate D by dividing 20*1 into 100 -

this approach might overestimate.)

The result is 4*(20*1+4) = 4*24 = 96, so D = 4, R

= 1.4.

100 - 96 = 4, append next pair of digits, result is

400.

400/(20*14) = 1 + fraction, 1*(20*14+1) =

%3D

1*281, so D = 1, R = 1.41.

400 - 281 = 119, appending next pair yields

11900.

11900/(20*141)

= 4 + fraction, 4*(20*141+4) =

4*2824 = 11296, so D = 4, R = 1.414, etc. etc.

What justifies this?

Suppose we know R, the best N-digit

approximation from this algorithm. Then the

next approximation will be 10*R + D, and D must

be the largest digit that satisfies

10R + D)? = (100R? + 20RD + D² )

(= 100R? + D(20R+ D) < radicand

You might be interested in
Given an array A of size N, and a number K. Task is to find out if it is possible to partition the array A into K contiguous sub
Dennis_Churaev [7]

Answer: First lets solve the Prerequisite part

Lets say we have an input array of N numbers {3,2,5,0,5}. We have to  find number of ways to divide this array into 3 contiguous parts having equal sum. So the output for the above input array will be 2 as there are 2 ways to divide the array. One is (3,2),(5),(0,5) and the other is (3,2),(5,0),(5).

Following are the steps to achieve the above outcome.

  • Let p and q point to the index of array such that sum of array elements from 0 to p-1 is equal to sum of array elements from p to q which is equal to the sum of array elements from q+1 to N-1.  
  • If we see the array we can tell that the sum of 3 contiguous parts is 5. So the condition would be that sum of all array elements should be equal to 5 or sum of each contiguous part is equal to sum of all array elements divided by 5.
  • Now create 2 arrays prefix and postfix of size of input array. Index p of prefix array carries sum of input array elements from index 0 to index p. Index q of postfix array carries sum of input array elements from index p to index N-1
  • Next move through prefix array suppose at the index p of prefix array : value of prefix array == (sum of all input array elements)/5.
  • Search the postfix array for p index found above. Search it starting from p+2 index. Increment the count variable by 1 when the value of postfix array =(sum of all input array elements)/5 and push that index of postfix array into a new array. Use searching algorithm on new array to calculate number of values in postfix array.

Now lets solve the main task

We have an array A of size N and a number K. where A[]= {1,6,3,4,7} N=5 and K=3. We have to find if its possible to partition A into 3 contiguous subarrays such that sum of elements in each subarray is the same. It is possible in this example. Here we have 3 partitions (1,6),(3,4),(7) and sum of each of subarrays is same (1+6) (3+4) (7) which is 7.

Following are the steps to achieve the above outcome.

  • In order create K contiguous subarrays where each subarray has equal sum, first check the condition that sum of all elements in the given array should be divisible by K. Lets name another array as arrsum that will be the size of array A. Traverse A from first to  last index and keep adding current element of A with previous value in arrsum. Example A contains (1,6,3,4,7} and arrsum has {1,7,10,14,21}
  • If the above condition holds, now check the condition that each subarray or partition has equal sum. Suppose we represent sum1 to sum of all element in given array and sum2 of sum of each partition then: sum2 = sum2 / K.
  • Compare arrsum to subarray, begining from index 0 and when it becomes equal to sum2 this means that end of one subarray is reached. Lets say index q is pointing to that subarray.
  • Now from q+1 index find p index in which following condition holds: (arrsum[p] - arrsum[q])=sum2
  • Continue the above step untill K contigous subarrays are found. This loop will break if, at some index, sum2 of any subarray gets greater than required sum2 (as we know that every contiguous subarray should contain equal sum).

A easier function Partition for this task:

int Partition(int A[], int N, int k) // A arra y of size N and number k

{      int sum = 0;    int count = 0;  //variables initialization    

   for(int j = 0; j < N; j++)  //Loop that calculates sum of A

  sum = sum + A[j];        

  if(sum % k != 0) //checks condition that sum of all elements of A should be //divisible by k

   return 0;        

   sum = sum / k;  

   int sum2 = 0;  //represents sum of subarray

  for(int j = 0; j < N; j++) // Loop on subarrays

  {      sum2=sum2 + A[j];  

   if(sum2 == sum)    { //these lines locates subarrays and sum of elements //of subarrays should be equal

       sum2 = 0;  

       count++;  }  }  

/*calculate count of subarrays whose

sum is equal to (sum of complete array/ k.)

if count == k print Yes else print No*/

if(count == k)    

return 1;  

   else

   return 0;  }

6 0
3 years ago
Def pig_latin(word): """ ------------------------------------------------------- Converts a word to Pig Latin. The conversion is
Virty [35]

def pig_latin(word):

   if word[0].lower() in 'aeiou':

       word = word + 'way'

   else:

       t=''

       for x in range(len(word)):

           if word[x].lower() in 'aeiou':

               break

           if word[x].lower() == 'y' and x>0:

               break

           else:

               t+=word[x].lower()

       if word[0].isupper():

           word = word[len(t):]+word[:len(t)].lower()+'ay'

           word = word.title()

       else:

           word = word[len(t):]+word[:len(t)].lower()+'ay'

   return word

word = 'test'

pl = pig_latin(word)

print(pl)

I wrote my code in python 3.8. I hope this helps.

5 0
3 years ago
Why would a user want to compress a large file before sending it as an email attachment?
Afina-wow [57]

to reduce the file size of the attachment

7 0
3 years ago
Read 2 more answers
The conflict between the user's goal for unfettered access to data and the security administrator's goal to protect that data is
rewona [7]

Answer: Access control

Explanation:Access control is the type of security facility that is provided to the systems in an organization. The functions carried out in maintaining the security of the system is done by authenticating , authorizing and identification of the users and related components . They are secured using the PINs , passwords, bio-metric scan etc.

The situation of the user wanting to have a unrestrained access towards data as well as maintaining the security is the done by access control.

8 0
3 years ago
Read 2 more answers
Which type of RAM is used exclusively in laptops?<br> a) SODIMM<br> b) DDR3<br> c) DDR<br> d) DDR4
Black_prince [1.1K]

Answer:

DDR3

Explanation:

6 0
3 years ago
Other questions:
  • What is the formula for calculating the average of cells<br> C2 through C30?
    15·1 answer
  • Match the following.
    8·2 answers
  • Examples of apps include pop-up windows, validation of webform inpts and images that change when a cursor passes over them
    12·1 answer
  • An application is to be written that would allow students to find out their GPA(double) and their total number of credits (an in
    15·1 answer
  • Working together, printer A and printer B would finish the task in 24 minutes. Printer A alone would finish the task in 60 minut
    8·1 answer
  • What are the four types of technical drawing?​
    9·1 answer
  • 30 points) Suppose you are given a string containing only the characters ( and ). In this problem, you will write a function to
    14·1 answer
  • What is Fill handle?
    12·1 answer
  • You defined a class and saved it as shoe.py.
    5·2 answers
  • What are the methods of gilding<br><br>nonsense will be immediately reported. ​
    7·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!