编写小段程序后运行出现整数相加.exe 中的 0x7248e42e (msvcr100d.dll) 处最可能的异常: 0xC0000005: 写入位置 0x00

compassur 2011-10-12 10:51:46
#include<stdio.h>
#include<stdlib.h>
main()
{
int a,b,c;
scanf("%d,%d,&a,&b");
c = a+b;
printf("the result is %d",c);
system("pause");
}

“整数相加.exe”: 已加载“F:\project\整数相加\Debug\整数相加.exe”,已加载符号。
“整数相加.exe”: 已加载“C:\Windows\System32\ntdll.dll”,Cannot find or open the PDB file
“整数相加.exe”: 已加载“C:\Windows\System32\kernel32.dll”,Cannot find or open the PDB file
“整数相加.exe”: 已加载“C:\Windows\System32\KernelBase.dll”,Cannot find or open the PDB file
“整数相加.exe”: 已加载“C:\Windows\System32\msvcr100d.dll”,已加载符号。
整数相加.exe 中的 0x7248e42e (msvcr100d.dll) 处最可能的异常: 0xC0000005: 写入位置 0x00000000 时发生访问冲突
整数相加.exe 中的 0x7248e42e (msvcr100d.dll) 处有未经处理的异常: 0xC0000005: 写入位置 0x00000000 时发生访问冲突
整数相加.exe 中的 0x7248e42e (msvcr100d.dll) 处最可能的异常: 0xC0000005: 写入位置 0x00000000 时发生访问冲突
整数相加.exe 中的 0x7248e42e (msvcr100d.dll) 处有未经处理的异常: 0xC0000005: 写入位置 0x00000000 时发生访问冲突
线程 '主线程' (0x1398) 已退出,返回值为 -1073741510 (0xc000013a)。
程序“[4996] 整数相加.exe: 本机”已退出,返回值为 -1073741510 (0xc000013a)。

我用的是visual studio 2010 win7系统


这是我第一次学习编程 希望大家帮助一下
...全文
322 2 打赏 收藏 转发到动态 举报
AI 作业
写回复
用AI写文章
2 条回复
切换为时间正序
请发表友善的回复…
发表回复
gooutofmyword 2012-04-17
  • 打赏
  • 举报
回复
scanf("%d%d",&b,&c);
luciferisnotsatan 2011-10-12
  • 打赏
  • 举报
回复
scanf("%d,%d,&a,&b")
改成
scanf("%d,%d",&a,&b)

70,020

社区成员

发帖
与我相关
我的任务
社区描述
C语言相关问题讨论
社区管理员
  • C语言
  • 花神庙码农
  • 架构师李肯
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告
暂无公告

试试用AI创作助手写篇文章吧