16 questions
char name[256]; printf(What's your name? ); scanf_s(%s, name,sizeof(name)); runs properly, but displays c4477,c6328 errorSo, char name[256]; printf(What's your name? ); scanf_s(%s, name,(unsigned cha...
I heard that if you receive a real data value from the scanf function, the data type of the factor value is automatically changed from float type to double type, so in that way, the int type data valu...
Hello!I fell into an infinite loop while practicing c, but I can't solve it.Here's the situation.If you receive an integer between 1 and 10, you have to exit the for statement and re-enter it when you...
while(scanf(%d %s %s, &s[n].id,s[n].name,s[n].major)==3) n++;What do you mean 3?
#include <stdio.h>int main(){ char str[] = hello; scanf(%c, str[0]); return; }This code is failing. hello is literal and cannot be accessed, but I want to change the information of str by saving...
Write a program that receives random characters and outputs them repeatedly.However, if you enter (Q), the program ends.Enter one character: ACharacters entered: AEnter one character: dCharacters ente...
You do not enter it as a string, but as a character.But char a; scanf_s(%c, &a); printf(%c, a);If I do this, there is no error. char a, b; scanf_s(%c%c, &a, &b); printf(%c%c, a, b);This ...
#include <stdio.h>#include <stdlib.h>#defineMAX_STACK_SIZE 100 // Declare Global Variableschar stack[MAX_STACK_SIZE];int top = -1; void stackFull() { fprintf(stderr, Stack is full, cannot...
I'm a beginner in C language.You want to store data in each string from a string through an array and output it.You want to enter each branch's revenue into an array and calculate the total and averag...
#include <stdio.h>int main(void){ char ch; int x, y; int result; printf(*****************\n); printf(A--- Add\n); printf(S--- Subtract\n); printf(M--- Multiply\n); printf(D--- Divide\n); printf(...
- 1 - | » |
© 2024 OneMinuteCode. All rights reserved.