SHARE
TWEET

Untitled

a guest Sep 19th, 2019 78 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. #include <stdio.h>
  2. using namespace std;
  3.  
  4. int main() {
  5.     int a;
  6.     scanf("%d",&a);
  7.     int ch1 = a % 10;
  8.     int ch2 = a % 100 / 10;
  9.     int ch3 = a % 1000 / 100;
  10.     int ch4 = a / 1000;
  11.     printf("%d\n", a % 10 + a % 100 / 10 + ch3 + ch4);
  12.     printf("%d", ch1 * ch2 * ch3 * ch4);
  13.     return 0;
  14. }
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top