wangqinghe:~/Desktop/code/ProgramDebug/staticlib/test$ gdb test
GNU gdb (Ubuntu 7.11.1-0ubuntu1~16.5) 7.11.1
Copyright (C) 2016 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law. Type "show copying"and"show warranty" for details.
This GDB was configured as "x86_64-linux-gnu".
Type "show configuration" for configuration details.
For bug reporting instructions, please see:
<http://www.gnu.org/software/gdb/bugs/>.
---Type <return> to continue, or q <return> to quit---
Find the GDB manual and other documentation resources online at:
<http://www.gnu.org/software/gdb/documentation/>.
For help, type "help".
Type "apropos word" to search for commands related to "word"...
Reading symbols from test...done.
(gdb) l
1 #include<iostream>
2 #include"add.h"34int main()
5 {
6int number1 = 10;7int number2 = 20;8 number1 = add(number1,number2);9std::cout << "result: " << number1 << std::endl;10 return 0;
(gdb) b 8
Breakpoint 1at0x4008ac: file test.cpp, line 8.
(gdb) r
Starting program: /home/user/Desktop/code/ProgramDebug/staticlib/test/test
Breakpoint 1, main () attest.cpp:88 number1 = add(number1,number2);
(gdb) s
add (a=10, b=20) atadd.c:55 return a+b;
(gdb)
6 }(gdb)
main () attest.cpp:99std::cout << "result: " << number1 << std::endl;
(gdb)
result:3010 return 0;
(gdb)
11 }(gdb)
【推荐】国内首个AI IDE,深度理解中文开发场景,立即下载体验Trae
【推荐】编程新体验,更懂你的AI,立即体验豆包MarsCode编程助手
【推荐】抖音旗下AI助手豆包,你的智能百科全书,全免费不限次数
【推荐】轻量又高性能的 SSH 工具 IShell:AI 加持,快人一步
· 全程不用写代码,我用AI程序员写了一个飞机大战
· MongoDB 8.0这个新功能碉堡了,比商业数据库还牛
· 记一次.NET内存居高不下排查解决与启示
· DeepSeek 开源周回顾「GitHub 热点速览」
· 白话解读 Dapr 1.15:你的「微服务管家」又秀新绝活了
2019-11-30 11-散列4 Hashing - Hard Version (30 分)
2019-11-30 11-散列3 QQ帐户的申请与登陆 (25 分)
2019-11-30 11-散列2 Hashing (25 分)
2018-11-30 KMP 串的模式匹配 (25 分)
2018-11-30 11-散列4 Hashing - Hard Version (30 分)