| 网站首页 | 业界新闻 | 小组 | 威客 | 人才 | 下载频道 | 博客 | 代码贴 | 在线编程 | 编程论坛
欢迎加入我们,一同切磋技术
用户名:   
 
密 码:  
共有 610 人关注过本帖, 1 人收藏
标题:一个小小的项目,请高手帮忙帮我哦,急!!!!!!!!!
只看楼主 加入收藏
langlangxion
Rank: 1
等 级:新手上路
帖 子:13
专家分:3
注 册:2009-6-13
结帖率:33.33%
收藏(1)
 问题点数:0 回复次数:5 
一个小小的项目,请高手帮忙帮我哦,急!!!!!!!!!
(编写一个简单的通讯录管理系统。通讯录包括:姓名、通讯地址、邮编、联系电话,现编写一个通讯录管理系统,可以对通讯录进行输入、显示、查找,通讯录保存到一个文件中。)这个是以前(正保杯)复赛的题目,做不出来,再过几天本人也要参加考试了,请高手帮我写写吧,对我肯定有很大的帮助,谢谢!

[ 本帖最后由 langlangxion 于 2009-10-25 17:25 编辑 ]
搜索更多相关主题的帖子: 小小的 项目 
2009-10-25 17:23
chiZ
Rank: 2
来 自:paradise
等 级:论坛游民
帖 子:27
专家分:99
注 册:2009-10-25
收藏
得分:0 
this problem is not hard. i don't rember the detail about C right now, but i can give you some ideas!
1. write a function: menu -use printf
2. write a function to distribute the jobs.
   in the function, you can use switch
   switch(option)
   {
        case 1: newCustomer();
              break;
        case 2: search()
              break;
        case 3: displayAllCustomers()
              break;
   }
3. write each sub-functions
  int newCustomers()
  {
     //use scanf to get the information from customers
    // use if else to ask wether the user wants to save
       if yes,  use fprintf or fputs to save into the file
       else  return;
  }
4.
   int search()
  {
    // use fscanf or fgets to get data from source file and store them by using pointers
    // you can search by name by using some algrithms. this depends on how you store the data
    return 1 if you get it. otherwise, return 0;

   }
5. void displayAllCustomers()
  {
      // this one is actually the first part of search
         you should get data from file. then print them out( you can use fscanf and fprintf here)

  }
i hope this can help you!! GOOD LUCK FOR YOUR TEST
2009-10-25 17:54
wuse
Rank: 1
等 级:新手上路
帖 子:6
专家分:5
注 册:2009-10-25
收藏
得分:0 
你很厉害,兄弟
2009-10-25 22:05
langlangxion
Rank: 1
等 级:新手上路
帖 子:13
专家分:3
注 册:2009-6-13
收藏
得分:0 
回复 2楼 chiZ
thank you !!!
2009-10-27 00:32
pgy
Rank: 11Rank: 11Rank: 11Rank: 11
来 自:C
等 级:小飞侠
威 望:8
帖 子:1248
专家分:2329
注 册:2009-9-23
收藏
得分:0 
以下是引用chiZ在2009-10-25 17:54:26的发言:

this problem is not hard. i don't rember the detail about C right now, but i can give you some ideas!
1. write a function: menu -use printf
2. write a function to distribute the jobs.
   in the functi ...
这个问题并不难。我不记得详细的关于C标准,但我可以给你一些想法!
1。写一个函数:菜单使用printf
2。编写一个函数来分配工作。
   在功能上,您可以使用切换
   开关(选项)
   
        案例1:newCustomer();
              中断;
        案例2:搜索()
              中断;
        案例3:displayAllCustomers()
              中断;
   
3。写出每个子功能
  整型 新客户()
   
      / /使用scanf获取客户信息
     / /使用其他要求,如果天气用户要保存
       如果有,使用fprintf或fputs保存到文件
       否则返回;
   
4。
   整型 搜索()
   
     / /使用fscanf或fgets来从源数据文件,并将其储存的使用指针
     / /您可以搜索按名称按使用一些algrithms。这取决于你如何存储数据
   如果你得到它,返回1。否则,返回0;

   
5。无返回值 displayAllCustomers()
   
       / /这一个是真正的搜索第一部分
         你应该从文件中读取数据。然后打印出来(可以使用fscanf和fprintf这里)

   
我希望这能帮助你!祝你好运,检查!

我可好玩啦...不信你玩玩^_^
2009-10-27 00:45
langlangxion
Rank: 1
等 级:新手上路
帖 子:13
专家分:3
注 册:2009-6-13
收藏
得分:0 
回复 5楼 pgy
对我很有帮助,谢谢!
2009-10-30 15:42
快速回复:一个小小的项目,请高手帮忙帮我哦,急!!!!!!!!!
数据加载中...
 
   



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

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