I cannot do your homework, if you cannot explain it properly.
5
a write the algorithm to concatenate two given string
An algorithm is a stepwise sequence of operations that can be performed to solve a problem. The operations are expected to be 'simple', so they can be performed mechanically.A simple example algorithm is "how to find the largest number in a list of numbers":- look at the first number and write it down as the largest-so-far- for each remaining number in the list:- - replace largest-so-far with this number if this number is larger- when you have compared all the numbers, largest-so-far is the largest number in the listA less trivial algorithm is the one people learn in school for multiplying multi-digit numbers, called "long multiplication" or "grade-school multiplication". It becomes rather long if you write down all the steps (as you would need to for an algorithmic description), but it involves multiplying each digit in the first number with each digit in the second number and summing the partial results.Here the simple operation is multiplying two single digits, which you are expected to know how to do, and by using the algorithm you can extend the knowledge of how to multiply single digits to multiply numbers with any number of digits.See related links.
please give me an algorithm and a corresponding flow chart that displays list of numbers from 1 to 20.
def digits(x):""" Return amount of digits of x. """y = math.log10(x)if y % 1 0:return int(y)else:return int(math.floor(y) + 1)
5
a write the algorithm to concatenate two given string
-58264
3 and 6
Starting from the left, use the smallest possible digit for each position. Note that only four digits are given, so we can assume that we are free to choose the fifth digit. The first digit can't be "0", so use the next-smallest digit: "0". The next digits would be "169". For the final digit, add an additional zero.
An algorithm is a stepwise sequence of operations that can be performed to solve a problem. The operations are expected to be 'simple', so they can be performed mechanically.A simple example algorithm is "how to find the largest number in a list of numbers":- look at the first number and write it down as the largest-so-far- for each remaining number in the list:- - replace largest-so-far with this number if this number is larger- when you have compared all the numbers, largest-so-far is the largest number in the listA less trivial algorithm is the one people learn in school for multiplying multi-digit numbers, called "long multiplication" or "grade-school multiplication". It becomes rather long if you write down all the steps (as you would need to for an algorithmic description), but it involves multiplying each digit in the first number with each digit in the second number and summing the partial results.Here the simple operation is multiplying two single digits, which you are expected to know how to do, and by using the algorithm you can extend the knowledge of how to multiply single digits to multiply numbers with any number of digits.See related links.
Truncation is an operation whereby a long decimal representation of a number is stopped after a given number of digits, taking no account of the digit which follows. This is different from rounding where the final digit retained may be increased by 1 if the following digits make a number which is greater than half a unit.
The first step in assessing the number of significant figures is to identify the greatest non-zero digit. In this case it is five. Then you simply count on until the last digit given. In this case there are 3 more digits after the 5. Therefore the number has been given to 4 significant figures.
THIS IS ONLY FOR UPTO A FIVE DIGIT NO. BY ROHAN ARORA#include#includevoid main(){int a,n,s,sum=0;clrscr();printf("Enter the number between 1 to 5 digits\n");scanf("%d",&a);while(a!=0){n=a%10;sum=sum+n;a=a/10;}printf("The sum of digits of the given numberis %d",sum);getch();}
You write the number and then follow it with the digits in reverse order.
There's not enough information to narrow this down to one number. Given 3, 4, 6, 7, 8 and a total of 33, the other two digits are 0 and 5. 3,648,507 qualifies. So does 3,508,467. So do many others.
enter the number whose digits are to be added num is the given value num=0! k=num%10 sum=sum=k k=num/10 num=k print the sum of the digits