473,748 Members | 4,178 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Number of occurences

4 New Member
Reading standard input and printing the number of occurences of each letter in graphic format as follows:

a: .....
b: ..
.
.
.
z: ...

where no. of dots= no.of occurences
Apr 10 '07 #1
7 1695
RedSon
5,000 Recognized Expert Expert
Sounds like an interesting problem. Thanks for sharing, but this forum is for asking questions. Did you want to ask a question, or were you content just to tell us about your assignment and leave it at that?
Apr 10 '07 #2
shubharamaswamy
4 New Member
I am sorry that I have forgotten to mention that.. I have tried to solve this problem and not very successful.. So I just wanna know any ways to solve this..
Apr 10 '07 #3
RedSon
5,000 Recognized Expert Expert
There are lots of ways to solve this. What work have you done to solve this? Have you read the chapters of your book that have information about this? Have you talked to your instructor about your questions? Have you searched google and thescripts for similar problems that have already been solved?
Apr 10 '07 #4
shubharamaswamy
4 New Member
Yes ofcourse.. I am able to solve half of the problem by geting the number of occurences with the use of pointers. But I just wanna know how to getit in graphic format.. N is that necessary that I have to ask my instructor before expressing any doubt in these forums?
Apr 10 '07 #5
RedSon
5,000 Recognized Expert Expert
The people on thescripts expect that you exhaust all your normal resources first, which means google, books, instructors should be consulted first. But there is no requirement that you must have asked your instructor first, even if there was there would be no way for us to enforce this rule so it would be ridiculous to make it.

What I don't understand is, if your program can already calculate the number of occurrences then why are you not able to just put a print statement in a loop that prints a dash or dot for each occurrence?
Apr 10 '07 #6
shubharamaswamy
4 New Member
I just wanna know the whole program
Apr 10 '07 #7
RedSon
5,000 Recognized Expert Expert
The experts on this site are more than happy to help you with your problems but they cannot do your assignment/program for you. Attempt the assignment/program yourself first and post questions regarding any difficulties you have or about a particular function of the code that you don't know how to achieve.

Please read the Posting Guidelines and particularly the Coursework Posting Guidlines.

Then when you are ready post a new question in this thread.

MODERATOR
Apr 10 '07 #8

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

Similar topics

4
14127
by: sibingpeter | last post by:
Hi there, Im trying to find the right way to code the loop to count the number of occurences of a given substring in a string. Im able to find the first occurence using the strstr function, but I just cant seem to think of the right loop that would continue searching after finding this first occurence. Could someone please help me out here?
1
3678
by: sunilkeswani | last post by:
Hi I am still new to access. I want to know how i can build a query which can display results from 4 different columns/fields Like. Field1 Field2 Field3 Field4 1 2 1 0 1 1 0 0
3
1600
by: M.N.A.Smadi | last post by:
hi; say i have a text file with a string ( say '(XYZ)') and I want to find the number of line where this string has occured. What is the best way to do that? what about if that string was say a 0 with leading and trailing white spaces, would that be any different? thanks moe smadi
3
1571
by: nightrosee | last post by:
hello every body how are you? I hope you are all having a nice day.. I have to write two methods, the first one counts the number of occurrences of a character ch in a string ( Numoccurs(char ch) ) and the second removes leading and trailing characters from a string ( Trim(string &str) ).. pleeeeeeeeeeeeeeeeeeeeeeeeeeeeeese help me
4
3379
by: Dameon | last post by:
Hi All, I have a process where I'd like to search the contents of a file(in a dir) for all occurences (or the count of) of a given string. My goal is to focus more on performance, as some of the files could be upwards of 25mb in size and time is important. I don't want to take the route of loading the text of the file into a giant string and searching it, but would rather focus on a performance-minded solution. Any sugesstions for a...
2
1968
by: kasala | last post by:
I get an xml document as input from other department. The input xml document i recieve has a particular word "rnx" which should not be there and my system doesn't support it. And there is also attribute xml:lang="EN" in some elements which should not be there. I am enclosing the code for reference. I used to remove the occurences manually...but now I need an assembly which can do that for me in C#.I have to remove the occurences of the word...
5
6928
by: Larry | last post by:
Dear all, I'm new to Python. I have a file (an image file actually) that I need to read pixel by pixel. It's an 8-bit integer type. I need to get the statistics like mean, standard deviation, etc., which I know a little bit already from reading numpy module. What I want to know is how to get the number of occurences of numeric element in an array. Say, b = array(()
1
4125
ajhayes
by: ajhayes | last post by:
I posted a few weeks ago about trying to set up a way to order by unit number (http://bytes.com/topic/access/answers/864507-need-help-setting-up-table-structure-ordering-unit) I'm trying to use a similar structure to what OldBirdman suggested in my previous post, but I'm a bit stuck. Here is what I've set up: tbl_Orders Order_Number Order_Date
3
2475
by: SLauren | last post by:
Hi, I am trying to find the records based on a search string which can be anything and can match any of the varchar fields in the table. Right now i am getting those records by using the combinations of "LIKE" and "OR" operators.But as per the requirements i also need to show the number of occurences of the search string that could match different varchar fields in a record?? Can anyone please suggest me how can i prepare this query?? ...
0
8987
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
8826
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
0
9366
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
9241
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
8239
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...
0
4597
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
4867
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
3303
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
2
2777
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

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.