.C Language Help: Counting Zeroes, Evaluating Series, and Reversing Numbers

Click For Summary

Discussion Overview

The discussion revolves around three programming questions related to the C language: counting specific characters in a string, evaluating a mathematical series, and reversing a number. The scope includes programming concepts and practical implementation in C.

Discussion Character

  • Homework-related
  • Technical explanation

Main Points Raised

  • One participant requests help with three specific programming tasks in C.
  • Another participant emphasizes the importance of showing prior work or asking more specific questions to gauge the requester's understanding.
  • A participant expresses their lack of knowledge regarding the first two questions, indicating they are a beginner in C programming.
  • There is a suggestion that the requester should have some foundational knowledge of C, such as reading strings and using loops and switch statements.
  • One participant encourages the requester to outline their program step-by-step to clarify their approach.
  • Repeatedly, participants stress that they will not complete the homework for the requester but are willing to guide them if they provide specific questions.

Areas of Agreement / Disagreement

Participants generally agree on the need for the requester to demonstrate some understanding of C programming before receiving assistance. There is no consensus on how to approach the programming tasks, as the requester has expressed uncertainty.

Contextual Notes

The discussion reflects varying levels of familiarity with C programming concepts, and some participants indicate that the requester may not have sufficient background knowledge to tackle the questions independently.

manipalmps
Messages
3
Reaction score
0
could some1 help me in these 3 questions of C language

Q1
Write a program to count the number to count the number of zero’s, one's, blank spaces and other characters using switch statement.

Q2
Write a program to evaluate the series
x-(x^3)/3!+)(x^5)/5!-(x^7)/7! ... up to (x^n)/n!

Q3
Write a program to print the entered number in reverse order
 
Physics news on Phys.org
Sure, we're here to help, but we're not going to do the work for you. First, you have to show us some work, or at least ask a more specific question. Don't be ashamed if you think or know it is wrong: a failed attempt is better than no attempt at all.

Otherwise we have no idea at all about your level of programming. Like: do you know how to write and compile a C program? Do you know about variables, loops, arrays, ...? Are you having problems converting the question to an algorithm or just implementing the algorithm in C?
 
bro i am a newbie to c
actually i have no idea for 1st and 2nd
i know a bit but not in full detail
 
Surely you must have some idea... if this is homework/coursework, I can't imagine that your teacher would have you write such programs without any knowledge of C at all.
For Q1, for example, you should at least know how to read a string from keyboard, how to loop through its characters and how a switch statement works. Do you know about cin/getline, for, and switch?
 
for,switch i know
 
So you can start by writing out as specifically and step-by-step as possible what your program should do. For example:

>Start of program
- Ask the user for input string
- Make four counters for zero, one, space and other
- Initialize the counters to zero
- ...
- ...
 
manipalmps said:
bro i am a newbie to c
actually i have no idea for 1st and 2nd
i know a bit but not in full detail

We do not do your work for you. If you have a specific question, post it. If you want us to do your schoolwork for you, you are at the wrong website.
 

Similar threads

  • · Replies 4 ·
Replies
4
Views
5K
  • · Replies 14 ·
Replies
14
Views
4K
  • · Replies 3 ·
Replies
3
Views
2K
  • · Replies 5 ·
Replies
5
Views
3K
Replies
5
Views
2K
  • · Replies 7 ·
Replies
7
Views
2K
  • · Replies 5 ·
Replies
5
Views
2K
  • · Replies 8 ·
Replies
8
Views
7K
  • · Replies 1 ·
Replies
1
Views
7K
Replies
4
Views
3K