Let "n" is that number and "occ" is the no of occurrence of a element "el" in "n".
so,
<pre>
i = n;
occ = 0; // Initializing "occ" to zero.
while(i > 0){
rem = i % 10; // This gives a digit in the number.
if(rem == el) occ++; // If "rem" is same as "el" then increament "occ".
i = i / 10; //By this we are extracting rem from number i.
}
printf("No of Occurrence of %d element is : %d", el, occ); // Printing the number of occurences
</pre>
that's it.
let the number to be searched for be stored in key
for(i=0;i<arraylength;i++)
{
if(arr[i]==key)
{
printf("found");
break;
}
}
if(i==arraylength)
printf("not found");
where arr is the array and arraylength is its length
i is a loop control variable
The greatest number is infinity.
Yes
1010
If you are using an array : sort using qsort() then take middle element.
You might be lucky and find the element in the first node, but equally you might be unlucky and not find it until the last element. The average case is that it takes half the number of nodes in the list.
The atomic number is the number of protons in the element. For example calcium has 20 protons, so that means it has an atomic number of 20. You can find the element's number on the periodic table; its usually the number on top of the element's symbol
the atomic number is the number of protons of an element. The atomic number specifically identifies an element. You can find it on the Periodic Table of Elements.
To find the total number of electrons in an element, first you need to look up the element's atomic number. That number tells you how many protons are in the element. Then, look up the net charge of the element. The number of protons subtracted by the elements net charge will give you the number of its electrons.
To find the number of neutrons in an atom, first find the atomic weight of the element and round that number to the nearest whole number. Then, find the atomic number of the element. Subtract that number from the atomic weight and the number of neutrons will be found.
We can find radon as a non metal element. Atomic number of it is 86.
how do you find the atomic number for an element?
Each chemical element has a specific number of protons; the number of protons is equal to atomic number of the element.
The atomic number of the element is the number of protons, therefore there has to be the same amount of electrons to protons.
We can find tellurium as a non metal element. Atomic number of it is 52.
Mass number = Number of Protons + Number of Neutrons
The number of protrons of whichever element you choose. Each element has an exact number of protrons.
We can find tin as a metal element. Atomic number of it is 50.