473,805 Members | 2,028 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Frequency and intervals in C

1 New Member
HI..could anyone help me out on this question?

Consider the marks scored by students of a programming module. Allow the user to enter the number of students. The user shall then enter the marks for each student. Thus if there are 10 students, the user will enter 10 marks.

The program must calculate
(i) the frequency for each mark
(ii) the interval which exists between identical marks

for e.g
46 37 28 87 76 83 76 38 76 37

frequency
46 --->1
37---->2
28---->1
87---->1
76---->3
83---->1
38---->1

interval between number 37 is 7 and between number 76 is 1.
Oct 15 '06 #1
0 1189

Sign in to post your reply or Sign up for a free account.

Similar topics

9
2157
by: christopher diggins | last post by:
I would like to survey how widespread the usage of smart pointers in C++ code is today. Any anecdotal experience about the frequency of usage of smart pointer for dynamic allocation in your own code or other people's code you have come across would be appreciated. I am also trying to identify the likelihood nad frequency of scenarios where smart pointer solutions would not be appropriate, i.e. for some reason such as performance or...
2
2680
by: Salmo Bytes | last post by:
I want to make an animated gif that runs through one loop and then stops. But I want to invoke it at random time intervals...so, for instance, a tight head shot of a person's face winks at the viewer once or twice per minute, at unpredictable intervals. I think I could figure out how to use rand() and setTimeout(...) to create the random time intervals, but I'm not sure about how to start the one-loop animated gif. Would I have to...
2
1349
by: Mike | last post by:
I'm more unsure of myself these days: Given a result set of rows with discrete date intevals; but rows may be non contiguous in nature; Can a simple, non cursor driven query produce a result with the min and max date intervals? eg. the result table R has the following rows key1|level1|05/01/01|10/01/02| key1|level1|01/01/01|04/30/01| key1|level1|11/10/00|12/31/00| key1|level1|06/01/00|10/09/00|
11
4384
by: NC Tim | last post by:
Hello, I think the question i have is fairly straightforward, but I can't seem to replicate the old SAS frequency procedure when I try to accomplish this in MS Access. anyway, i have about 10 questions on a survey that have a possible response range from 0-4. what I would like to do is simply show that for each question we had x amount of responses in each category, which amount to x percentage of all
9
4673
by: RFJ | last post by:
I've got a list of annual turnovers for about fifty companies and I want to summarise them by bands. A simple version would be : eg: Annual_Turnover Count Up to 5million 5 5 to 10 million 37 10 to 20 million 8 As a relative beginner in Access (XP) this is stretching me. Can SKS point me in the right direction.
19
3147
by: jason_box | last post by:
I'm alittle new at C and I'm trying to write a simple program that will record the frequency of words and just print it out. It is suppose to take stdin and I heard it's only a few lines but I'm not sure where to start. The only example I have to work with is if you ran the program say: File list contains: This is a test.
7
4060
by: Udhay | last post by:
How to get the frequency of an audio file and how to separate the low and high frequency of an audio file
2
2450
by: oormilarev | last post by:
dear all i want and as fast as possible a working C program for the following problem. i have an array values consisting of 'n' float values say ranging from 0 - 18. i want to get the frequencies of the values in class intervals of 0 - 1.99, 2 - 3.99, 4 - 5.99 etc. My attempts do not give me the proper results. especially for the first class interval 0 - 1.99. HELP !!! My program #include<stdio.h> #define maxrl 10 #define bins 10
1
1780
by: lenygold via DBMonster.com | last post by:
I found this query on older thread and i can not uderstand output interval pairs: How to find min and max values in date intervals: -------------------------------------------------- Input: CREATE TABLE INTERVALS (key CHAR(5) NOT NULL ,level CHAR(7) NOT NULL ,date_from DATE NOT NULL
0
9718
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look ! Part I. Meaning of...
0
10363
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
0
10107
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
9186
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
7649
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
6876
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
5678
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
4327
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
3
3008
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.