SlideShare a Scribd company logo
1 of 1
Download to read offline
Instructions
Write a program whose main function is merely a collection of variable declarations and function
calls. This program reads a text and outputs the letters, together with their counts, as explained
below in the function printResult. (There can be no global variables! All information must be
passed in and out of the functions. Use a structure to store the information.) Your program must
consist of at least the following functions:
Function openFile: Opens the input and output files. You must pass the file streams as parameters
(by reference, of course). If the file does not exist, the program should print an appropriate
message ("The input file does not exist.") and exit. The program must ask the user for the
names of the input and output files.
Function count: Counts every occurrence of capital letters A-Z and small letters a-z in the text file
opened in the function openFile. This information must go into an array of structures. The array
must be passed as a parameter, and the file identifier must also be passed as a parameter.
Function printResult: Prints the number of capital letters and small letters, as well as the
percentage of capital letters for every letter A-Z and the percentage of small letters for every letter
a-z. The percentages should look like this: "25%".This information must come from an array of
structures, and this array must be passed as a parameter.
Your program should prompt the user for name of the input file, then the name of the output file.

More Related Content

Similar to Instructions Write a program whose main function is merely a.pdf

Hello guys please make sure program runs well USING C anyth.pdf
Hello guys please make sure program runs well USING C anyth.pdfHello guys please make sure program runs well USING C anyth.pdf
Hello guys please make sure program runs well USING C anyth.pdfactioncbe1
 
Hello, I need help with the following assignmentThis assignment w.pdf
Hello, I need help with the following assignmentThis assignment w.pdfHello, I need help with the following assignmentThis assignment w.pdf
Hello, I need help with the following assignmentThis assignment w.pdfnamarta88
 
Typescript language extension of java script
Typescript language extension of java scriptTypescript language extension of java script
Typescript language extension of java scriptmichaelaaron25322
 
Reaction StatisticsBackgroundWhen collecting experimental data f.pdf
Reaction StatisticsBackgroundWhen collecting experimental data f.pdfReaction StatisticsBackgroundWhen collecting experimental data f.pdf
Reaction StatisticsBackgroundWhen collecting experimental data f.pdffashionbigchennai
 
Sample for Simple C Program - R.D.Sivakumar
Sample for Simple C Program - R.D.SivakumarSample for Simple C Program - R.D.Sivakumar
Sample for Simple C Program - R.D.SivakumarSivakumar R D .
 
IIM.Com-FIT-Unit2(14.9.2021 TO 30.9.2021).pptx
IIM.Com-FIT-Unit2(14.9.2021 TO 30.9.2021).pptxIIM.Com-FIT-Unit2(14.9.2021 TO 30.9.2021).pptx
IIM.Com-FIT-Unit2(14.9.2021 TO 30.9.2021).pptxrajkumar490591
 
Programming For As Comp
Programming For As CompProgramming For As Comp
Programming For As CompDavid Halliday
 
Programming For As Comp
Programming For As CompProgramming For As Comp
Programming For As CompDavid Halliday
 
Looping in PythonLab8 lecture slides.pptx
Looping in PythonLab8 lecture slides.pptxLooping in PythonLab8 lecture slides.pptx
Looping in PythonLab8 lecture slides.pptxadihartanto7
 
Functions in c++, presentation, short and sweet presentation, and details of ...
Functions in c++, presentation, short and sweet presentation, and details of ...Functions in c++, presentation, short and sweet presentation, and details of ...
Functions in c++, presentation, short and sweet presentation, and details of ...Sar
 
Tutorial basic of c ++lesson 1 eng ver
Tutorial basic of c ++lesson 1 eng verTutorial basic of c ++lesson 1 eng ver
Tutorial basic of c ++lesson 1 eng verQrembiezs Intruder
 
Lab6: I/O and Arrays
Lab6: I/O and ArraysLab6: I/O and Arrays
Lab6: I/O and Arraysenidcruz
 
Program 1 – CS 344This assignment asks you to write a bash.docx
Program 1 – CS 344This assignment asks you to write a bash.docxProgram 1 – CS 344This assignment asks you to write a bash.docx
Program 1 – CS 344This assignment asks you to write a bash.docxwkyra78
 
Write a functionWe want a function, called split, that has three p.pdf
Write a functionWe want a function, called split, that has three p.pdfWrite a functionWe want a function, called split, that has three p.pdf
Write a functionWe want a function, called split, that has three p.pdfarchanenterprises
 
C programming session 08
C programming session 08C programming session 08
C programming session 08Dushmanta Nath
 

Similar to Instructions Write a program whose main function is merely a.pdf (20)

Hello guys please make sure program runs well USING C anyth.pdf
Hello guys please make sure program runs well USING C anyth.pdfHello guys please make sure program runs well USING C anyth.pdf
Hello guys please make sure program runs well USING C anyth.pdf
 
Hello, I need help with the following assignmentThis assignment w.pdf
Hello, I need help with the following assignmentThis assignment w.pdfHello, I need help with the following assignmentThis assignment w.pdf
Hello, I need help with the following assignmentThis assignment w.pdf
 
Typescript language extension of java script
Typescript language extension of java scriptTypescript language extension of java script
Typescript language extension of java script
 
Reaction StatisticsBackgroundWhen collecting experimental data f.pdf
Reaction StatisticsBackgroundWhen collecting experimental data f.pdfReaction StatisticsBackgroundWhen collecting experimental data f.pdf
Reaction StatisticsBackgroundWhen collecting experimental data f.pdf
 
Sample for Simple C Program - R.D.Sivakumar
Sample for Simple C Program - R.D.SivakumarSample for Simple C Program - R.D.Sivakumar
Sample for Simple C Program - R.D.Sivakumar
 
C-PROGRAM
C-PROGRAMC-PROGRAM
C-PROGRAM
 
IIM.Com-FIT-Unit2(14.9.2021 TO 30.9.2021).pptx
IIM.Com-FIT-Unit2(14.9.2021 TO 30.9.2021).pptxIIM.Com-FIT-Unit2(14.9.2021 TO 30.9.2021).pptx
IIM.Com-FIT-Unit2(14.9.2021 TO 30.9.2021).pptx
 
Programming For As Comp
Programming For As CompProgramming For As Comp
Programming For As Comp
 
Programming For As Comp
Programming For As CompProgramming For As Comp
Programming For As Comp
 
Looping in PythonLab8 lecture slides.pptx
Looping in PythonLab8 lecture slides.pptxLooping in PythonLab8 lecture slides.pptx
Looping in PythonLab8 lecture slides.pptx
 
Functions in c++, presentation, short and sweet presentation, and details of ...
Functions in c++, presentation, short and sweet presentation, and details of ...Functions in c++, presentation, short and sweet presentation, and details of ...
Functions in c++, presentation, short and sweet presentation, and details of ...
 
Satz1
Satz1Satz1
Satz1
 
Lecture 11 - Functions
Lecture 11 - FunctionsLecture 11 - Functions
Lecture 11 - Functions
 
Tutorial basic of c ++lesson 1 eng ver
Tutorial basic of c ++lesson 1 eng verTutorial basic of c ++lesson 1 eng ver
Tutorial basic of c ++lesson 1 eng ver
 
Lab6: I/O and Arrays
Lab6: I/O and ArraysLab6: I/O and Arrays
Lab6: I/O and Arrays
 
Turbo pascal
Turbo pascalTurbo pascal
Turbo pascal
 
Program 1 – CS 344This assignment asks you to write a bash.docx
Program 1 – CS 344This assignment asks you to write a bash.docxProgram 1 – CS 344This assignment asks you to write a bash.docx
Program 1 – CS 344This assignment asks you to write a bash.docx
 
Functions in C.pptx
Functions in C.pptxFunctions in C.pptx
Functions in C.pptx
 
Write a functionWe want a function, called split, that has three p.pdf
Write a functionWe want a function, called split, that has three p.pdfWrite a functionWe want a function, called split, that has three p.pdf
Write a functionWe want a function, called split, that has three p.pdf
 
C programming session 08
C programming session 08C programming session 08
C programming session 08
 

More from adinathknit

It had been seven weeks since her surgery and Marlene was On.pdf
It had been seven weeks since her surgery and Marlene was On.pdfIt had been seven weeks since her surgery and Marlene was On.pdf
It had been seven weeks since her surgery and Marlene was On.pdfadinathknit
 
ISuppose that the marginal propensity to save is dya5057y+.pdf
ISuppose that the marginal propensity to save is dya5057y+.pdfISuppose that the marginal propensity to save is dya5057y+.pdf
ISuppose that the marginal propensity to save is dya5057y+.pdfadinathknit
 
IT 7113 Data Visualization and Dashboard Development Project.pdf
IT 7113 Data Visualization and Dashboard Development Project.pdfIT 7113 Data Visualization and Dashboard Development Project.pdf
IT 7113 Data Visualization and Dashboard Development Project.pdfadinathknit
 
issurecoit thevend at teedes ERetiat a patin puinen ra soo .pdf
issurecoit thevend at teedes ERetiat a patin puinen ra soo .pdfissurecoit thevend at teedes ERetiat a patin puinen ra soo .pdf
issurecoit thevend at teedes ERetiat a patin puinen ra soo .pdfadinathknit
 
ISO 9000 uluslararas kalite standarddr Standardn en son dei.pdf
ISO 9000 uluslararas kalite standarddr Standardn en son dei.pdfISO 9000 uluslararas kalite standarddr Standardn en son dei.pdf
ISO 9000 uluslararas kalite standarddr Standardn en son dei.pdfadinathknit
 
Isabella Penrose la gerente general le pidi a la Sra Sul.pdf
Isabella Penrose la gerente general le pidi a la Sra Sul.pdfIsabella Penrose la gerente general le pidi a la Sra Sul.pdf
Isabella Penrose la gerente general le pidi a la Sra Sul.pdfadinathknit
 
Isaiah is a 9 vear old malewho was diaanosed with Cerebra.pdf
Isaiah is a 9 vear old malewho was diaanosed with Cerebra.pdfIsaiah is a 9 vear old malewho was diaanosed with Cerebra.pdf
Isaiah is a 9 vear old malewho was diaanosed with Cerebra.pdfadinathknit
 
Is there convincing evidence that less than half of American.pdf
Is there convincing evidence that less than half of American.pdfIs there convincing evidence that less than half of American.pdf
Is there convincing evidence that less than half of American.pdfadinathknit
 
Is the following statement true or false and why this sta.pdf
Is the following statement true or false and why this sta.pdfIs the following statement true or false and why this sta.pdf
Is the following statement true or false and why this sta.pdfadinathknit
 
Is the coefficient 0 1 or not defined Please provide expl.pdf
Is the coefficient 0 1 or not defined Please provide expl.pdfIs the coefficient 0 1 or not defined Please provide expl.pdf
Is the coefficient 0 1 or not defined Please provide expl.pdfadinathknit
 
Is the drawn T the doubled version of T If not what is th.pdf
Is the drawn T the doubled version of T If not what is th.pdfIs the drawn T the doubled version of T If not what is th.pdf
Is the drawn T the doubled version of T If not what is th.pdfadinathknit
 
Is SPI filtering for packets that are part of ongoing commun.pdf
Is SPI filtering for packets that are part of ongoing commun.pdfIs SPI filtering for packets that are part of ongoing commun.pdf
Is SPI filtering for packets that are part of ongoing commun.pdfadinathknit
 
Is it possible to create a bottom navigation with two option.pdf
Is it possible to create a bottom navigation with two option.pdfIs it possible to create a bottom navigation with two option.pdf
Is it possible to create a bottom navigation with two option.pdfadinathknit
 
Is gain of function correct Colors indicate range of gene e.pdf
Is gain of function correct Colors indicate range of gene e.pdfIs gain of function correct Colors indicate range of gene e.pdf
Is gain of function correct Colors indicate range of gene e.pdfadinathknit
 
irketlerin zellikleri ile ilgili olarak aadakilerden hangis.pdf
irketlerin zellikleri ile ilgili olarak aadakilerden hangis.pdfirketlerin zellikleri ile ilgili olarak aadakilerden hangis.pdf
irketlerin zellikleri ile ilgili olarak aadakilerden hangis.pdfadinathknit
 
irketimizin aadaki nakit aklarna sahip bir projesi bulunmakt.pdf
irketimizin aadaki nakit aklarna sahip bir projesi bulunmakt.pdfirketimizin aadaki nakit aklarna sahip bir projesi bulunmakt.pdf
irketimizin aadaki nakit aklarna sahip bir projesi bulunmakt.pdfadinathknit
 
Ire ntanin Cedar of ontry into recinient cell Given the abo.pdf
Ire ntanin Cedar of ontry into recinient cell Given the abo.pdfIre ntanin Cedar of ontry into recinient cell Given the abo.pdf
Ire ntanin Cedar of ontry into recinient cell Given the abo.pdfadinathknit
 
IP Fragmentation Consider sending a 2000 byte datagram in.pdf
IP Fragmentation Consider sending a 2000 byte datagram in.pdfIP Fragmentation Consider sending a 2000 byte datagram in.pdf
IP Fragmentation Consider sending a 2000 byte datagram in.pdfadinathknit
 
Investors have a utility function over wealth of Retur.pdf
Investors have a utility function over wealth of   Retur.pdfInvestors have a utility function over wealth of   Retur.pdf
Investors have a utility function over wealth of Retur.pdfadinathknit
 
Investors have different risk preferences Most people are n.pdf
Investors have different risk preferences Most people are n.pdfInvestors have different risk preferences Most people are n.pdf
Investors have different risk preferences Most people are n.pdfadinathknit
 

More from adinathknit (20)

It had been seven weeks since her surgery and Marlene was On.pdf
It had been seven weeks since her surgery and Marlene was On.pdfIt had been seven weeks since her surgery and Marlene was On.pdf
It had been seven weeks since her surgery and Marlene was On.pdf
 
ISuppose that the marginal propensity to save is dya5057y+.pdf
ISuppose that the marginal propensity to save is dya5057y+.pdfISuppose that the marginal propensity to save is dya5057y+.pdf
ISuppose that the marginal propensity to save is dya5057y+.pdf
 
IT 7113 Data Visualization and Dashboard Development Project.pdf
IT 7113 Data Visualization and Dashboard Development Project.pdfIT 7113 Data Visualization and Dashboard Development Project.pdf
IT 7113 Data Visualization and Dashboard Development Project.pdf
 
issurecoit thevend at teedes ERetiat a patin puinen ra soo .pdf
issurecoit thevend at teedes ERetiat a patin puinen ra soo .pdfissurecoit thevend at teedes ERetiat a patin puinen ra soo .pdf
issurecoit thevend at teedes ERetiat a patin puinen ra soo .pdf
 
ISO 9000 uluslararas kalite standarddr Standardn en son dei.pdf
ISO 9000 uluslararas kalite standarddr Standardn en son dei.pdfISO 9000 uluslararas kalite standarddr Standardn en son dei.pdf
ISO 9000 uluslararas kalite standarddr Standardn en son dei.pdf
 
Isabella Penrose la gerente general le pidi a la Sra Sul.pdf
Isabella Penrose la gerente general le pidi a la Sra Sul.pdfIsabella Penrose la gerente general le pidi a la Sra Sul.pdf
Isabella Penrose la gerente general le pidi a la Sra Sul.pdf
 
Isaiah is a 9 vear old malewho was diaanosed with Cerebra.pdf
Isaiah is a 9 vear old malewho was diaanosed with Cerebra.pdfIsaiah is a 9 vear old malewho was diaanosed with Cerebra.pdf
Isaiah is a 9 vear old malewho was diaanosed with Cerebra.pdf
 
Is there convincing evidence that less than half of American.pdf
Is there convincing evidence that less than half of American.pdfIs there convincing evidence that less than half of American.pdf
Is there convincing evidence that less than half of American.pdf
 
Is the following statement true or false and why this sta.pdf
Is the following statement true or false and why this sta.pdfIs the following statement true or false and why this sta.pdf
Is the following statement true or false and why this sta.pdf
 
Is the coefficient 0 1 or not defined Please provide expl.pdf
Is the coefficient 0 1 or not defined Please provide expl.pdfIs the coefficient 0 1 or not defined Please provide expl.pdf
Is the coefficient 0 1 or not defined Please provide expl.pdf
 
Is the drawn T the doubled version of T If not what is th.pdf
Is the drawn T the doubled version of T If not what is th.pdfIs the drawn T the doubled version of T If not what is th.pdf
Is the drawn T the doubled version of T If not what is th.pdf
 
Is SPI filtering for packets that are part of ongoing commun.pdf
Is SPI filtering for packets that are part of ongoing commun.pdfIs SPI filtering for packets that are part of ongoing commun.pdf
Is SPI filtering for packets that are part of ongoing commun.pdf
 
Is it possible to create a bottom navigation with two option.pdf
Is it possible to create a bottom navigation with two option.pdfIs it possible to create a bottom navigation with two option.pdf
Is it possible to create a bottom navigation with two option.pdf
 
Is gain of function correct Colors indicate range of gene e.pdf
Is gain of function correct Colors indicate range of gene e.pdfIs gain of function correct Colors indicate range of gene e.pdf
Is gain of function correct Colors indicate range of gene e.pdf
 
irketlerin zellikleri ile ilgili olarak aadakilerden hangis.pdf
irketlerin zellikleri ile ilgili olarak aadakilerden hangis.pdfirketlerin zellikleri ile ilgili olarak aadakilerden hangis.pdf
irketlerin zellikleri ile ilgili olarak aadakilerden hangis.pdf
 
irketimizin aadaki nakit aklarna sahip bir projesi bulunmakt.pdf
irketimizin aadaki nakit aklarna sahip bir projesi bulunmakt.pdfirketimizin aadaki nakit aklarna sahip bir projesi bulunmakt.pdf
irketimizin aadaki nakit aklarna sahip bir projesi bulunmakt.pdf
 
Ire ntanin Cedar of ontry into recinient cell Given the abo.pdf
Ire ntanin Cedar of ontry into recinient cell Given the abo.pdfIre ntanin Cedar of ontry into recinient cell Given the abo.pdf
Ire ntanin Cedar of ontry into recinient cell Given the abo.pdf
 
IP Fragmentation Consider sending a 2000 byte datagram in.pdf
IP Fragmentation Consider sending a 2000 byte datagram in.pdfIP Fragmentation Consider sending a 2000 byte datagram in.pdf
IP Fragmentation Consider sending a 2000 byte datagram in.pdf
 
Investors have a utility function over wealth of Retur.pdf
Investors have a utility function over wealth of   Retur.pdfInvestors have a utility function over wealth of   Retur.pdf
Investors have a utility function over wealth of Retur.pdf
 
Investors have different risk preferences Most people are n.pdf
Investors have different risk preferences Most people are n.pdfInvestors have different risk preferences Most people are n.pdf
Investors have different risk preferences Most people are n.pdf
 

Recently uploaded

Kisan Call Centre - To harness potential of ICT in Agriculture by answer farm...
Kisan Call Centre - To harness potential of ICT in Agriculture by answer farm...Kisan Call Centre - To harness potential of ICT in Agriculture by answer farm...
Kisan Call Centre - To harness potential of ICT in Agriculture by answer farm...Krashi Coaching
 
The byproduct of sericulture in different industries.pptx
The byproduct of sericulture in different industries.pptxThe byproduct of sericulture in different industries.pptx
The byproduct of sericulture in different industries.pptxShobhayan Kirtania
 
Activity 01 - Artificial Culture (1).pdf
Activity 01 - Artificial Culture (1).pdfActivity 01 - Artificial Culture (1).pdf
Activity 01 - Artificial Culture (1).pdfciinovamais
 
1029 - Danh muc Sach Giao Khoa 10 . pdf
1029 -  Danh muc Sach Giao Khoa 10 . pdf1029 -  Danh muc Sach Giao Khoa 10 . pdf
1029 - Danh muc Sach Giao Khoa 10 . pdfQucHHunhnh
 
BAG TECHNIQUE Bag technique-a tool making use of public health bag through wh...
BAG TECHNIQUE Bag technique-a tool making use of public health bag through wh...BAG TECHNIQUE Bag technique-a tool making use of public health bag through wh...
BAG TECHNIQUE Bag technique-a tool making use of public health bag through wh...Sapna Thakur
 
Web & Social Media Analytics Previous Year Question Paper.pdf
Web & Social Media Analytics Previous Year Question Paper.pdfWeb & Social Media Analytics Previous Year Question Paper.pdf
Web & Social Media Analytics Previous Year Question Paper.pdfJayanti Pande
 
Sanyam Choudhary Chemistry practical.pdf
Sanyam Choudhary Chemistry practical.pdfSanyam Choudhary Chemistry practical.pdf
Sanyam Choudhary Chemistry practical.pdfsanyamsingh5019
 
mini mental status format.docx
mini    mental       status     format.docxmini    mental       status     format.docx
mini mental status format.docxPoojaSen20
 
CARE OF CHILD IN INCUBATOR..........pptx
CARE OF CHILD IN INCUBATOR..........pptxCARE OF CHILD IN INCUBATOR..........pptx
CARE OF CHILD IN INCUBATOR..........pptxGaneshChakor2
 
Paris 2024 Olympic Geographies - an activity
Paris 2024 Olympic Geographies - an activityParis 2024 Olympic Geographies - an activity
Paris 2024 Olympic Geographies - an activityGeoBlogs
 
Russian Call Girls in Andheri Airport Mumbai WhatsApp 9167673311 💞 Full Nigh...
Russian Call Girls in Andheri Airport Mumbai WhatsApp  9167673311 💞 Full Nigh...Russian Call Girls in Andheri Airport Mumbai WhatsApp  9167673311 💞 Full Nigh...
Russian Call Girls in Andheri Airport Mumbai WhatsApp 9167673311 💞 Full Nigh...Pooja Nehwal
 
Student login on Anyboli platform.helpin
Student login on Anyboli platform.helpinStudent login on Anyboli platform.helpin
Student login on Anyboli platform.helpinRaunakKeshri1
 
Interactive Powerpoint_How to Master effective communication
Interactive Powerpoint_How to Master effective communicationInteractive Powerpoint_How to Master effective communication
Interactive Powerpoint_How to Master effective communicationnomboosow
 
Advanced Views - Calendar View in Odoo 17
Advanced Views - Calendar View in Odoo 17Advanced Views - Calendar View in Odoo 17
Advanced Views - Calendar View in Odoo 17Celine George
 
Ecosystem Interactions Class Discussion Presentation in Blue Green Lined Styl...
Ecosystem Interactions Class Discussion Presentation in Blue Green Lined Styl...Ecosystem Interactions Class Discussion Presentation in Blue Green Lined Styl...
Ecosystem Interactions Class Discussion Presentation in Blue Green Lined Styl...fonyou31
 
JAPAN: ORGANISATION OF PMDA, PHARMACEUTICAL LAWS & REGULATIONS, TYPES OF REGI...
JAPAN: ORGANISATION OF PMDA, PHARMACEUTICAL LAWS & REGULATIONS, TYPES OF REGI...JAPAN: ORGANISATION OF PMDA, PHARMACEUTICAL LAWS & REGULATIONS, TYPES OF REGI...
JAPAN: ORGANISATION OF PMDA, PHARMACEUTICAL LAWS & REGULATIONS, TYPES OF REGI...anjaliyadav012327
 
Measures of Central Tendency: Mean, Median and Mode
Measures of Central Tendency: Mean, Median and ModeMeasures of Central Tendency: Mean, Median and Mode
Measures of Central Tendency: Mean, Median and ModeThiyagu K
 
Call Girls in Dwarka Mor Delhi Contact Us 9654467111
Call Girls in Dwarka Mor Delhi Contact Us 9654467111Call Girls in Dwarka Mor Delhi Contact Us 9654467111
Call Girls in Dwarka Mor Delhi Contact Us 9654467111Sapana Sha
 
Grant Readiness 101 TechSoup and Remy Consulting
Grant Readiness 101 TechSoup and Remy ConsultingGrant Readiness 101 TechSoup and Remy Consulting
Grant Readiness 101 TechSoup and Remy ConsultingTechSoup
 

Recently uploaded (20)

Kisan Call Centre - To harness potential of ICT in Agriculture by answer farm...
Kisan Call Centre - To harness potential of ICT in Agriculture by answer farm...Kisan Call Centre - To harness potential of ICT in Agriculture by answer farm...
Kisan Call Centre - To harness potential of ICT in Agriculture by answer farm...
 
The byproduct of sericulture in different industries.pptx
The byproduct of sericulture in different industries.pptxThe byproduct of sericulture in different industries.pptx
The byproduct of sericulture in different industries.pptx
 
Activity 01 - Artificial Culture (1).pdf
Activity 01 - Artificial Culture (1).pdfActivity 01 - Artificial Culture (1).pdf
Activity 01 - Artificial Culture (1).pdf
 
1029 - Danh muc Sach Giao Khoa 10 . pdf
1029 -  Danh muc Sach Giao Khoa 10 . pdf1029 -  Danh muc Sach Giao Khoa 10 . pdf
1029 - Danh muc Sach Giao Khoa 10 . pdf
 
BAG TECHNIQUE Bag technique-a tool making use of public health bag through wh...
BAG TECHNIQUE Bag technique-a tool making use of public health bag through wh...BAG TECHNIQUE Bag technique-a tool making use of public health bag through wh...
BAG TECHNIQUE Bag technique-a tool making use of public health bag through wh...
 
Web & Social Media Analytics Previous Year Question Paper.pdf
Web & Social Media Analytics Previous Year Question Paper.pdfWeb & Social Media Analytics Previous Year Question Paper.pdf
Web & Social Media Analytics Previous Year Question Paper.pdf
 
Mattingly "AI & Prompt Design: The Basics of Prompt Design"
Mattingly "AI & Prompt Design: The Basics of Prompt Design"Mattingly "AI & Prompt Design: The Basics of Prompt Design"
Mattingly "AI & Prompt Design: The Basics of Prompt Design"
 
Sanyam Choudhary Chemistry practical.pdf
Sanyam Choudhary Chemistry practical.pdfSanyam Choudhary Chemistry practical.pdf
Sanyam Choudhary Chemistry practical.pdf
 
mini mental status format.docx
mini    mental       status     format.docxmini    mental       status     format.docx
mini mental status format.docx
 
CARE OF CHILD IN INCUBATOR..........pptx
CARE OF CHILD IN INCUBATOR..........pptxCARE OF CHILD IN INCUBATOR..........pptx
CARE OF CHILD IN INCUBATOR..........pptx
 
Paris 2024 Olympic Geographies - an activity
Paris 2024 Olympic Geographies - an activityParis 2024 Olympic Geographies - an activity
Paris 2024 Olympic Geographies - an activity
 
Russian Call Girls in Andheri Airport Mumbai WhatsApp 9167673311 💞 Full Nigh...
Russian Call Girls in Andheri Airport Mumbai WhatsApp  9167673311 💞 Full Nigh...Russian Call Girls in Andheri Airport Mumbai WhatsApp  9167673311 💞 Full Nigh...
Russian Call Girls in Andheri Airport Mumbai WhatsApp 9167673311 💞 Full Nigh...
 
Student login on Anyboli platform.helpin
Student login on Anyboli platform.helpinStudent login on Anyboli platform.helpin
Student login on Anyboli platform.helpin
 
Interactive Powerpoint_How to Master effective communication
Interactive Powerpoint_How to Master effective communicationInteractive Powerpoint_How to Master effective communication
Interactive Powerpoint_How to Master effective communication
 
Advanced Views - Calendar View in Odoo 17
Advanced Views - Calendar View in Odoo 17Advanced Views - Calendar View in Odoo 17
Advanced Views - Calendar View in Odoo 17
 
Ecosystem Interactions Class Discussion Presentation in Blue Green Lined Styl...
Ecosystem Interactions Class Discussion Presentation in Blue Green Lined Styl...Ecosystem Interactions Class Discussion Presentation in Blue Green Lined Styl...
Ecosystem Interactions Class Discussion Presentation in Blue Green Lined Styl...
 
JAPAN: ORGANISATION OF PMDA, PHARMACEUTICAL LAWS & REGULATIONS, TYPES OF REGI...
JAPAN: ORGANISATION OF PMDA, PHARMACEUTICAL LAWS & REGULATIONS, TYPES OF REGI...JAPAN: ORGANISATION OF PMDA, PHARMACEUTICAL LAWS & REGULATIONS, TYPES OF REGI...
JAPAN: ORGANISATION OF PMDA, PHARMACEUTICAL LAWS & REGULATIONS, TYPES OF REGI...
 
Measures of Central Tendency: Mean, Median and Mode
Measures of Central Tendency: Mean, Median and ModeMeasures of Central Tendency: Mean, Median and Mode
Measures of Central Tendency: Mean, Median and Mode
 
Call Girls in Dwarka Mor Delhi Contact Us 9654467111
Call Girls in Dwarka Mor Delhi Contact Us 9654467111Call Girls in Dwarka Mor Delhi Contact Us 9654467111
Call Girls in Dwarka Mor Delhi Contact Us 9654467111
 
Grant Readiness 101 TechSoup and Remy Consulting
Grant Readiness 101 TechSoup and Remy ConsultingGrant Readiness 101 TechSoup and Remy Consulting
Grant Readiness 101 TechSoup and Remy Consulting
 

Instructions Write a program whose main function is merely a.pdf

  • 1. Instructions Write a program whose main function is merely a collection of variable declarations and function calls. This program reads a text and outputs the letters, together with their counts, as explained below in the function printResult. (There can be no global variables! All information must be passed in and out of the functions. Use a structure to store the information.) Your program must consist of at least the following functions: Function openFile: Opens the input and output files. You must pass the file streams as parameters (by reference, of course). If the file does not exist, the program should print an appropriate message ("The input file does not exist.") and exit. The program must ask the user for the names of the input and output files. Function count: Counts every occurrence of capital letters A-Z and small letters a-z in the text file opened in the function openFile. This information must go into an array of structures. The array must be passed as a parameter, and the file identifier must also be passed as a parameter. Function printResult: Prints the number of capital letters and small letters, as well as the percentage of capital letters for every letter A-Z and the percentage of small letters for every letter a-z. The percentages should look like this: "25%".This information must come from an array of structures, and this array must be passed as a parameter. Your program should prompt the user for name of the input file, then the name of the output file.