Question
Given a first (long long) integer (Y) representing the data to analyze and alter in this program, then a second integer (X) corresponding to the
Given a first (long long) integer (Y) representing the data to analyze and alter in this program, then a second integer (X) corresponding to the size of a number to extract from the first integer Y, identify the largest value in Y composed of X consecutive and adjacent digits. Divide this largest value by two, round it to the nearest whole number, and replace it into the number Y. Your program will need to validate that the first integer is positive and the second integer is both positive and not greater than the number of digits in the first input. Do this in C90 and don't use for loop.
Problem: Given a first (long long) integer (Y) representing the data to analyze and alter in this program, then a second integer (X) corresponding to the size of a number to extract from the first integer Y, identify the largest value in Y composed of X consecutive and adjacent digits. Divide this largest value by two, round it to the nearest whole number, and replace it into the number Y. Your program will need to validate that the first integer is positive and the second integer is both positive and not greater than the number of digits in the first inputStep by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started