PRF192_-_SP_2024_-_PE06_1886.webp
H

PRF192_-_SP_2024_-_PE06_1886.webp

The given Q1.c file already contains statements to enter data for the variable n. You write the statements check whether n is a perfect number or not (a perfect number is a number that has the sum of its divisors equal to itself). If true then return 1, otherwise return 0.
Notes:
- You can create new function(s) if you see it is necessary.
- Do not edit given statements in the main function.
2 of 3 Paper No: 1
Sample input and output:
-Input: n = 5
Output for marking:
OUTPUT:0
-Input: n = 6
Output for marking:
OUTPUT:
1
Zoom

+ 88%
Close
Chưa có bình luận nào.

Thông tin

Category
PRF192
Thêm bởi
Hạnh Phúc
Ngày thêm
Lượt xem
2,459
Lượt bình luận
0
Rating
0.00 star(s) 0 đánh giá

Image metadata

Filename
PRF192_-_SP_2024_-_PE06_1886.webp
File size
107.8 KB
Dimensions
1920px x 813px

Share this media

Back
Bên trên Bottom