C第三章
来源:互联网 发布:c 并行编程 编辑:程序博客网 时间:2024/06/06 00:56
1.题目内容:
编写一个程序, 接收用户录入的日期信息并且将其显示出来. 其中, 输入日期的形式为月/日/年(mm/dd/yy), 输出日期的形式为年月日(yy.mm.dd)。
以下为程序的运行结果示例:
Enter a date (mm/dd/yy):
12/03/2015↙
You entered the date: 2015.12.03
输入格式: "%d/%d/%d"
输出格式:
输入提示信息:"Enter a date (mm/dd/yy):\n"
输出格式:"You entered the date: %04d.%02d.%02d\n"
#include <stdio.h> int main() { printf("Enter a date (mm/dd/yy): "); int year = 0, month = 0, day = 0; scanf("%d/%d/%d", &month, &day, &year); printf("You entered the date %02d%02d%02d", year, month, day); return 0;
2.
阅读全文
0 0
- [C++]第三章 数据类型
- C++primer 第三章
- C++primer 第三章
- C语言第三章
- C第三章
- 第三章: C语言程序设计初步
- 第三章 - 数据和C
- 第三章,C++中的C
- 《C现代方法》第三章
- 第三章 C语言程序设计初步
- C 谭浩强 (第三章) char
- C算法 读书笔记 第三章
- c语言程序设计第三章题解
- [C++]第三章 2014.11.30
- 第三章 数据和C
- C Primer Plus 第三章
- Objective-C 程序设计 第三章
- 第三章:C语言特性
- liunx (centos) JDK环境配置
- JAVA线程间协作:wait.notify.notifyAll
- FZU
- 仿淘宝、京东、美团使用ViewPager+GridView实现左右滑动查看更多分类导航功能
- 学习JavaScript的总结(一)
- C第三章
- kotlin基本语法
- Android 工具adb报错 unknown host service
- JavaScript:原生JS实现图片懒加载
- 专题一关键字的剖析----2.aoto,register,static分析
- OpenCV|图片与视频的相互转换(C++&Python)
- 【LeetCode】616. Add Bold Tag in String
- Cocoa Core Competencies 的Object creation 和IOS面试题示例:写一个NSString类的实现
- JavaScript 函数声明和函数表达式