CFanatic

Go Back   CFanatic > Programming > C++ Programming

Join CFanatic Forum Now

Class Project topic posted under C++ Programming which is a part of Programming category in CFanatic Forum
Reply
 
Thread Tools Display Modes
  #1  
Old 09-11-2006, 11:40 PM
Junior Member
 
Join Date: Sep 2006
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
aaholland is on a distinguished road
| More
Class Project

I am writing a program for my college class It has to record a password, but it cant display it on the screen. It is a unix based enviroment. Does this look correct to you guys?


Code:
 main()
{
  int  i;
  char buffer[80];            
  initscr();                

  printw("Please enter a password => ");    
  refresh();                
  noecho();                
                    
  while((buffer[i] = getch()) != '\n') i++;

  printw("\nPassword is %s - press return to continue.",buffer);
  refresh();
  getch();

  endwin();                 }
Reply With Quote
Reply

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 Off
Pingbacks are Off
Refbacks are Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
get Class johny10151981 Win32 Programming 1 10-07-2008 03:58 AM
sizeof for a class coderzone C Programming 2 06-05-2007 10:29 PM
How can you get the current class name without using StackTrace? codeunlock C# Programming 0 04-29-2007 12:42 AM
Mini Project Using C vmanojnair C Programming 0 12-31-2006 01:22 AM

 

Advertisement

CFanatic Search
Custom Search

Advertisement

All times are GMT -5. The time now is 02:17 AM.



Powered by vBulletin® Version 3.7.4
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.
Search Engine Optimization by vBSEO ©2010, Crawlability, Inc.
Cfanatic.com is a premier member of the IDG TechNetwork. For advertising opportunities contact here
Get Paid for Working on Projects Matching Your Expertise at Go4Expert's Jobs Board