| 网站首页 | 业界新闻 | 小组 | 威客 | 人才 | 下载频道 | 博客 | 代码贴 | 在线编程 | 编程论坛
欢迎加入我们,一同切磋技术
用户名:   
 
密 码:  
共有 1278 人关注过本帖
标题:身份验证
取消只看楼主 加入收藏
冰封谷主
Rank: 4
等 级:贵宾
威 望:10
帖 子:226
专家分:20
注 册:2005-1-7
收藏
 问题点数:0 回复次数:0 
身份验证
using System;
class Myclass
{
 static void Main()
 {
  string name="lengmianren";
  int password=3123486;
  int i=4;
  Found :
  Console.WriteLine("Please input your name:");
  string Name=Console.ReadLine();
  Console.WriteLine("Please input your password:");
  int Password=int.Parse(Console.ReadLine());
  if(Name==name&Password==password)
  {
   Console.WriteLine("Welcome to bingfengguzhu's index.");
  }
  else
  {
   i--;
   if(i>=1)
   {
    Console.WriteLine("Sorry,your input is wrong,please input again,but you have only "+i+" chance.");
    goto Found;
   }
   else
   {
    Console.WriteLine("想进来。^-^");
   }
  }
  System.Threading.Thread.Sleep(3000);
 }
}
搜索更多相关主题的帖子: 身份 验证 
2005-04-05 15:18
快速回复:身份验证
数据加载中...
 
   



关于我们 | 广告合作 | 编程中国 | 清除Cookies | TOP | 手机版

编程中国 版权所有,并保留所有权利。
Powered by Discuz, Processed in 0.011510 second(s), 8 queries.
Copyright©2004-2024, BCCN.NET, All Rights Reserved