Code Newbie
News     Forums     Search     Members     Sign Up    

My Code Newbie
Username

Password

Articles/Snippets
ASP Classic
ASP.NET
C
C#
C++
HTML / CSS
Java
Javascript
Linux / BSD
Perl
PHP
Python
Ruby
SQL
VB 6
VB.NET

C.N. Friends
  Planet Rome

Link to Us!
Code Newbie
  Code Newbie
    forums
Old 10-22-2004, 02:31 AM   #1 (permalink)
Spooky
Registered User
 
Spooky's Avatar
 
Join Date: Oct 2004
Posts: 1
Spooky is on a distinguished road
Simple C program HELP!

This can be a very VERY simple little function in c for the most of you but i'am a c beginner and i need to get this working and i don't have much time to do it...

I need to insert an '-' (MINUS) before a sequence of lowercase letters that ends with a lowercase vowel.

ex: in the console i do ...
./program
asdfasda&hasssda7GUASDA8o9sssasdas

and the result is ->

-asdfasda&-hasssda7GUASDA8-o9sssasdas

i have to do this without no pointers ... just simple arrays and strings programing.
just one more thing, this must be a function that is called in the main and in there it must have a printf(...) that gives me the result i need... something like this

in main():

function(input,output);
printf(output);

(just for example)

if you have any ideias how can i do this, plz help...
if you could send some code examples it would be very nice

thanks in advance for the time.

Spooky.

Last edited by Spooky; 10-22-2004 at 03:18 AM.
Spooky is offline   Reply With Quote
Old 10-22-2004, 07:26 AM   #2 (permalink)
Kernel_Killer
Regular Contributor
 
Kernel_Killer's Avatar
 
Join Date: Feb 2003
Location: indisclosed
Posts: 210
Kernel_Killer is on a distinguished road
I would use a for statement to do this with the condition being any letter !=[a,e,i,o,u], and another loop to find the vowel. Maybe just inputting each character into an array and using a counter in another loop might help. Just some thoughts.
__________________
Network Synapse
Screaming Electron
Kernel_Killer is offline   Reply With Quote
Reply

Bookmarks

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
c simple question if13121 Standard C, C++ 10 11-01-2004 06:29 AM
c simple question problem with switch case if13121 Standard C, C++ 1 10-24-2004 09:43 PM
simple c question if13121 Standard C, C++ 3 10-18-2004 10:20 PM
math not quite accurate in C program uman Standard C, C++ 4 09-27-2004 05:19 PM


All times are GMT -8. The time now is 11:31 PM.


Powered by vBulletin® Version 3.7.0
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Search Engine Optimization by vBSEO 3.0.0 RC8





Copyright © 2000-2008, Milano Interactive
Web Hosting provided by Portal 360 Web Hosting