Hello everyone.
So I’m a newbie in the C-programming business and this is my first task with questions that I have. This is the practical task:
A factory in an industrial zone produces 1,000 devices daily to local consumption (statewide and export). Given that 0.05% of the devices manufactured in the factory are disqualified during quality tests, disassembled and their parts are recycled, write a #C program that calculates how many normal devices can be supplied daily for local distribution and export, and how many devices are disassembled after disqualification.
So that's my program, but I canÂ’t get it right, both in terms of the numbers and in terms of half a device that will be calculated as one whole device. So how should I fine-tune the code to get everything done properly?
Thanks in advance for the help.Code:#include<stdio.h> void main() { int x,y,z; x = 1000; y = 1000 * 0.0005; z = x - y; printf("Proper devices that can be supplied daily for distribution and export: %d \n", &z); printf("Disqualified devices (for disassembly): %d", &y); }