摘 要:“C 语言程序设计”课程是计算机类专业的一门基础课程,旨在引导学生建立逻辑思维,体会编程的乐趣;然而市面上绝大多数教材中的案例,多以解析数学题、科学常数等为主,学习起来呆板乏味,因此引入时下非常流行的“抢红包”游 戏,比起做数学题更接“地气”,“抢红包”程序用到了 if-else、循环、函数、数组等知识,几乎涵盖课程大纲中需要学生掌握的所有知识点,是一个很好的综合项目,让学生自己玩自己编写的游戏,学生更加有学习的动力和成就感,对学习这门课程有很大的促进作用。
关键词:C 语言;项目驱动;教学案例;抢红包
中图分类号:TP312 文献标识码:A 文章编号:2096-4706(2020)04-0095-03
An Analysis of the Teaching Case of “C Language Programming”
——Taking the Implementation of Red Packet Algorithm as an Example
JI Huijin
(Department of Information Technology,Hubei Polytechnic Institute,Xiaogan 432000,China)
Abstract:“C Language Programming” is a basic course for computer major. It aims to guide students to establish logical thinking and experience the fun of programming;however,most of the cases in the textbooks on the market are mainly based on the analysis of mathematical problems and scientific constants,which are dull to learn. Therefore,the popular game of “snatching red envelopes” is introduced,which is more “earthly” than doing mathematical problems,“snatching red envelopes” program uses if-else,cycle,function,array and other knowledge,almost covering all the knowledge points that students need to master in the curriculum outline. It is a good comprehensive project,so that students can play their own games,and students have more motivation and sense of success,which has a great role in promoting the learning of such courses.
Keywords:C language;project driven;teaching cases;snatching red envelopes
课题项目:湖北省教育科学规划一般课题(2019GB150),主持人:王亮
参考文献:
[1] 谭浩强 .C 程序设计(第 5 版) [M]. 北京:清华大学出版社,2017.
[2] 本 • 克莱蒙 .C 程序设计新思维(第 2 版) [M]. 赵岩, 译 . 北京:人民邮电出版社,2018.
[3] 王亮 .《C 语言程序设计》循环结构教学案例研究 [J]. 科技视界,2018(1):60-61.
作者简介:纪辉进(1977-),男,汉族,湖北黄陂人,讲师,本科,主要研究方向:软件技术教学。