1 & 4 because social media’s are your identity and posts show what you’re doing and what you’re posting about yourself / other people.
Answer:
The algorithm is as follows
1. Start
2. Declare Integer N
3. Input N
4. While N > 0:
4.1 Print(N%10)
4.2 N = N/10
5. Stop
Explanation:
This line starts the algorithm
1. Start
This declares an integer variable
2. Declare Integer N
Here, the program gets user input N
3. Input N
The while iteration begins here and it is repeated as long as N is greater than 0
4. While N > 0:
This calculates and prints N modulus 10; Modulus of 10 gets the individual digit of the input number
4.1 Print(N%10)
This remove the printed digit
4.2 N = N/10
The algorithm ends here
5. Stop
<u>Bonus:</u>
The algorithm in Python is as follows:
<em>n = 102</em>
<em>while n>0:</em>
<em> print(int(n%10))</em>
<em> n= int(n/10)</em>
<em> </em>
Answer:An object
Explanation: An objects play an important role as the real world component/entity which display any element which are sourced through their behaviors and different states. Object are the entities that are required in the program for the making the program easier and simpler to understand .
Example- computer can be considered as the object which is related with the real world.
Answer:
a) bytes
b) hertz
c) 1) hertz and 2) bytes
Explanation:
A byte is the basic unit of information and data stored in a computer storage. Hence, the storage capability of a drive will be measured in Bytes. On the other hand speed of processor is measured in terms of number of cycles made per second i.e hertz. Hence, the higher the value of hertz the higher is the speed of the computer.
Answer:
Here it is
Explanation:
#include <iostream>
using namespace std;
int main()
{
int a, b;
cin >> a >> b;
int nr_digits1 = 0, nr_digits2 = 0;
int sum1 = 0, sum2 = 0;
int max_digit1 = 0, max_digit2 = 0;
while (a > 1)
{
int digit = a % 10;
nr_digits1 += 1;
sum1 += digit;
if (digit > max_digit1)
{
max_digit1 = digit;
}
a /= 10;
}
while (b > 1)
{
int digit = b % 10;
nr_digits2 += 1;
sum2 += digit;
if (digit > max_digit2)
{
max_digit2 = digit;
}
b /= 10;
}
cout << "For a: \n" << " No. of digits: " << nr_digits1 << "\n";
cout << " Sum of digits: " << sum1 << "\n";
cout << " Max digit: " << max_digit1 << "\n";
cout << "\n";
cout << "For b: \n" << " No. of digits: " << nr_digits2 << "\n";
cout << " Sum of digits: " << sum2 << "\n";
cout << " Max digit: " << max_digit2 << "\n";
return 0;
}