given a string of integers, write a program to generate an output string as follow 1)from the input ints, filter the integers that are perfect squeares 2)for each perfect square obtained from step 1 find its factorial, if the factorial of the numb is trailing by zeros, three digits present before the trailing zeros shoud be appended to output string if not trailing by zeros append last three digits to output string if there is ad receding zero it is ignored a) if the num is 2 it does not have any trailing zeros and there is only on digit in it append 2 output b) if the num is 5 it has one trailing zero and before the trailing zero there are only two present so append 12 to output d) if the num is 9 it has one trailing zero before railing zero there are 5 digits so append e) if the num is 12 then ......

Database System Concepts
7th Edition
ISBN:9780078022159
Author:Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Publisher:Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Chapter1: Introduction
Section: Chapter Questions
Problem 1PE
icon
Related questions
Question

given a string of integers, write a program to generate an output string as follow

1)from the input ints, filter the integers that are perfect squeares

2)for each perfect square obtained from step 1 find its factorial, if the factorial of the numb is trailing by zeros, three digits present before the trailing zeros shoud be appended to output string if not trailing by zeros append last three digits to output string if there is ad receding zero it is ignored

a) if the num is 2 it does not have any trailing zeros and there is only on digit in it append 2 output

b) if the num is 5 it has one trailing zero and before the trailing zero there are only two present so append 12 to output

d) if the num is 9 it has one trailing zero before railing zero there are 5 digits so append e) if the num is 12 then ...... 

Expert Solution
steps

Step by step

Solved in 2 steps with 2 images

Blurred answer
Similar questions
Recommended textbooks for you
Database System Concepts
Database System Concepts
Computer Science
ISBN:
9780078022159
Author:
Abraham Silberschatz Professor, Henry F. Korth, S. Sudarshan
Publisher:
McGraw-Hill Education
Starting Out with Python (4th Edition)
Starting Out with Python (4th Edition)
Computer Science
ISBN:
9780134444321
Author:
Tony Gaddis
Publisher:
PEARSON
Digital Fundamentals (11th Edition)
Digital Fundamentals (11th Edition)
Computer Science
ISBN:
9780132737968
Author:
Thomas L. Floyd
Publisher:
PEARSON
C How to Program (8th Edition)
C How to Program (8th Edition)
Computer Science
ISBN:
9780133976892
Author:
Paul J. Deitel, Harvey Deitel
Publisher:
PEARSON
Database Systems: Design, Implementation, & Manag…
Database Systems: Design, Implementation, & Manag…
Computer Science
ISBN:
9781337627900
Author:
Carlos Coronel, Steven Morris
Publisher:
Cengage Learning
Programmable Logic Controllers
Programmable Logic Controllers
Computer Science
ISBN:
9780073373843
Author:
Frank D. Petruzella
Publisher:
McGraw-Hill Education