Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include "stdafx.h"
- #include <math.h>
- double sum_pdv(double p, int q)
- {
- p=111.44;
- return p*q*1.2;
- }
- void swap(int *x,int *y)
- {
- int z=*x;
- *x=*y;
- *y=z;
- return;
- }
- int _tmain(int argc, _TCHAR* argv[])
- {
- setlocale(LC_ALL, "Ukrainian");
- double price=100.10;
- int quantity = 23,a,b;
- double sum=sum_pdv(price, quantity);
- printf("Сума з ПДВ для ціни %6.2f і к-сті %d є %6.2f грн.\n",
- price, quantity, sum);
- a=6; b=8;
- printf("\n%d %d\t",a,b);
- swap(&a,&b);
- printf("%d %d",a,b);
- return 0;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement