write a function that prints a table of values of sines and cosine in between 0 and 1

0 votes
asked Mar 23 by Adithya S (170 points)
edited Mar 23 by Adithya S

3 Answers

0 votes
answered Mar 24 by Tårún Såthyå9.0 (140 points)

void main
0 votes
answered Mar 25 by Ravon Salcido STUDENT (140 points)
F=9/5C+ 32 = 32.0 F
–1 vote
answered Apr 5 by Luigi Rodorigo (260 points)
You mean something like that?
#include <stdio.h>
#include <stdint.h>
#include <math.h>

void print_sin_cos(double step) {

    for (double x=0;x<=1;x+=step) {
        printf("sin(%f)=%f\n", x, sin(x));
        printf("cos(%f)=%f\n", x, cos(x));


int main()
    double step = 0;
    printf("Enter the desired step (es. 0.1):\n");
    if (scanf("%lf", &step)==1)

Welcome to OnlineGDB Q&A, where you can ask questions related to programming and OnlineGDB IDE and and receive answers from other members of the community.