- #include <math.h>
-
-
- int getCiffer(int number,int cifdex){
- return ((int)(number/pow(10,cifdex-1)))%10;
- }
- int main(int argc, char *argv[])
- {
- std::cout<<getCiffer(6354,3);
- system("PAUSE");
- return EXIT_SUCCESS;
- }
Indlæg senest redigeret d. 21.09.2008 22:10 af Bruger #5620