Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

please use function value and write on the mathlab and everything will be clear Write a program that displays the numeric value of a word.

image text in transcribedplease use function value and write on the mathlab and everything will be clear

Write a program that displays the numeric value of a word. Word will be entered by the user. Numeric val ues of English letters are given below Following function will be primary function convertStringToNumeric) function a) Following function will he used to calculate the numeric value othe word. Eunction total-getNumericValue(s) If the word contains any value different from lower case English letters, numeric value will be accepted as D and will be written a waming message. . b) You have to use aa vector to declare the numeric values DI Ihe lower case letters * Lettersa b c d e f Numeric Values 1 2 3 4 5 6 78 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 Following function will be used to write the numeric value o the word or warning message to the file NumericStrings.txt function writeNumValuetoEile(f, s The content of the NumericStrings.xt that is created at the previous runs will not be deleted. The numeric value othe word or warning message will he appended to the previous ones The following functionl read the content of the " NumericSirings. xfile. The conten will be displayed at the Command Window Eunction ReadNumValueFromPile(f) d) The function "function total-getNumericValue(s)" will be called in o "function WriteNumValueToFile(f, s)" e) The functions "unction WriteNumValueToPile(, and Eunction ReadNunValueFromPile(f) will be called in o "unction convertStri ric 1 Enter a text: simge Content of the "Numericstrings.txt" file: Numeric Value of "simge" Is 53 S is capital in Simge Enter a text: Simge Content of the "Numericstrings.txt" file: -Numeric Value of "simge" Is 53 - "Simge" Contains Non-Lower Case Character(s) 3 "cankaya university" contains a blank Enter a text: cankaya university Content of the "Numericstrings.txt" file: Numeric Value of "simge" Is 53 "Simge" Contains Non-Lower Case Character (s) -"cankaya university" Contains Non-Lower Case Character (s)

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Graph Databases New Opportunities For Connected Data

Authors: Ian Robinson, Jim Webber, Emil Eifrem

2nd Edition

1491930896, 978-1491930892

More Books

Students also viewed these Databases questions