Welcome, Guest: Register On Nairaland / LOGIN! / Trending / Recent / NewStats: 3,195,284 members, 7,957,730 topics. Date: Tuesday, 24 September 2024 at 06:33 PM |
Nairaland Forum / Science/Technology / Programming / Urgent! Plz Help - C Programming Problem (1219 Views)
Help: C Language And MPI ? (urgent Plz) / C Programming Challenge To Be Solved Under 10 Minutes (2) (3) (4)
Urgent! Plz Help - C Programming Problem by lctewand(f): 11:41am On Dec 21, 2009 |
plz i need an urgent solution to this question, " write a program tha enteres a line of text, stores it in an array and then displays it backwards, allow the lenght of the line to be unspecified but assume it will not exceed 80 characters and it should be ended by pressing the enter key, " plz guyz i really need ur help cos i dont even hav an idea of where to start from, |
Re: Urgent! Plz Help - C Programming Problem by Ogim: 1:39pm On Dec 21, 2009 |
#include <stdio.h> #include <string.h> int _getch(void); Void main() { char str[80]; int len; scanf("%s",str); len=strlen(str); int i,j; char temp; for (i=0,j=len-1;i<j;i++,j--) { temp=str[i]; str[i]=str[j]; str[j]=temp; } printf(str); _getch(); } |
Re: Urgent! Plz Help - C Programming Problem by Ogim: 1:41pm On Dec 21, 2009 |
#include <stdio.h> |
Re: Urgent! Plz Help - C Programming Problem by candylips(m): 3:12pm On Dec 21, 2009 |
@poster you should be doing your home work assignment yourself |
Re: Urgent! Plz Help - C Programming Problem by lctewand(f): 10:30pm On Dec 21, 2009 |
@ candylips thanks but i didnt know what 2 do so i had 2 come 2 d masters @ ogim thanks a lot am running it now nd i think its correct cos its only givin me 1 error which i think is due 2 my compiler, |
Re: Urgent! Plz Help - C Programming Problem by javalove(m): 2:09pm On Dec 25, 2009 |
that question is from "k&r", if your lecturer gave you the question, he must be lazy or he wants you all to pass. |
Re: Urgent! Plz Help - C Programming Problem by lctewand(f): 7:57am On Dec 30, 2009 |
javalove: sorry what is k&r |
Re: Urgent! Plz Help - C Programming Problem by Ogim: 9:38am On Dec 30, 2009 |
Kernighan & Ritchie also known as K & R where the once who design the original c language. If you realy want to learn c programming start with the free books at http://cslibrary.stanford.edu/ |
(1) (Reply)
Pls Niaralanders, Help Mi Wit Dis Ms Excel Trouble / J2ME App Selectively Working On Phones / Here Are 53 Courses & 1,989 Video Tutorials For Mobile App Development
(Go Up)
Sections: politics (1) business autos (1) jobs (1) career education (1) romance computers phones travel sports fashion health religion celebs tv-movies music-radio literature webmasters programming techmarket Links: (1) (2) (3) (4) (5) (6) (7) (8) (9) (10) Nairaland - Copyright © 2005 - 2024 Oluwaseun Osewa. All rights reserved. See How To Advertise. 10 |