Info

Diese Frage ist geschlossen. Öffnen Sie sie erneut, um sie zu bearbeiten oder zu beantworten.

Need help creating a program please

3 Ansichten (letzte 30 Tage)
Cameron Tiegs
Cameron Tiegs am 9 Mai 2020
Geschlossen: John D'Errico am 9 Mai 2020
A main function is required which accepts a single 1xn cell array of decimal numbers as characters and must perform long addition on these n whole numbers to return the sum as a character array. This function must be named AccuSumNet and it must use no other inputs and produce no other outputs apart from those described in this brief. You may make use of a single subroutine in AccuSumNet. The program must be entirely silent i.e. it may not employ any GUI or display to the console.
  1 Kommentar
James Tursa
James Tursa am 9 Mai 2020
What have you done so far? What specific problems are you having with your code? As I read the problem, an example of an input and output would be
Input: {'83','42'}
Output: '125'
That is, the input is a cell array, and each cell contains a whole number as a character string. You need to add them up as if they were decimal numbers and produce the single character string output containing the sum.

Antworten (0)

Diese Frage ist geschlossen.

Tags

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by