Questions tagged [duration]

The tag has no usage guidance.

Filter by
Sorted by
Tagged with
0 votes
1 answer

pset 3 Duration non object type error

Getting error message at compile. helpers.c:17:18: error: non-object type 'int (string)' (aka 'int (char *)') is not assignable duration = numerator; My code is as follows: int duration(...
-1 votes
1 answer

Incompatible Integer to Pointer Conversion

int duration(string fraction) { int numerator; int denominator; int factor; // The factor will store the value of the number which the fraction needs to be multiplied for its ...
  • 19
1 vote
0 answers

PSET 3 Duration

I need help with duration function. I am taking the string fraction = "x/y" and am assuming I can use the statement. int x = fraction[0] - '0' to assign the value of the character at fraction[0]...
  • 11
0 votes
1 answer

how to get a substring from a string in C; pset3 helper function: duration

I am trying to convert a fraction string (X/Y) into integers, however, I am having trouble. I made my function dynamic meaning X and Y can be any length. Here is my code: int duration(string ...
0 votes
1 answer

Pset3 - 'Error Loading Audio File'

Whenever I attempt to synthesize a new .wav file, the notes come out extremely long (over 1:30 each when played in windows media player) and my .wav file is over 200 MB when inputting the notes to ...
  • 5