由买买提看人间百态

boards

本页内容为未名空间相应帖子的节选和存档,一周内的贴子最多显示50字,超过一周显示500字 访问原贴
Programming版 - how to do it ?=======Problem – coding in c++
相关主题
Why do I need to use "plain" pointer?C++ Q05: pointer to constant variable
一个简单的小问题find start point of loop from linked list
请问可以这样定义struct吗?C++ Q93 - Q95 (转载)
is smart_ptr really that good?c++ pointers are iterators, why?
[合集] pointer in Cint F::*x = &F::x是什么意思?
pointer overflowc++ 里用到pointer 的地方我们尽可能用smart pointer吗?
about STL functor and function pointers不如各位高手挑个专题讲讲C++11吧
what's the purpose of pointer to pointers?Go adopts JavaScript’s idea of semicolon insertion
相关话题的讨论汇总
话题: problem话题: coding话题: merging话题: c++话题: pointer
进入Programming版参与讨论
1 (共1页)
i***0
发帖数: 8469
1
how to do it ?=======Problem – coding in c++
I have two node pointer which may be in same link list or not.
The function should return me pointer where they are merging if they are
merging.
If the node pointers are not merging, it should return null pointer.
j********r
发帖数: 21
2
Your problem is not well-defined nor described. Here are some hints ...
Assume the lists are not cicular. p and s are two pointers in lists.
If p and s are in the same list, one must be behind the other. If not, they
will never find (meet) each other by tracking down the lists.
Assume p is behind s, so use s traces down the list to check for p. vice
verse.
Similar techniques can be applied to cicular cases.
1 (共1页)
进入Programming版参与讨论
相关主题
Go adopts JavaScript’s idea of semicolon insertion[合集] pointer in C
最新的MS面试题 (转载)pointer overflow
有什么工具可以检查内存泄漏么about STL functor and function pointers
一个C#使用C++.NET类库的问题what's the purpose of pointer to pointers?
Why do I need to use "plain" pointer?C++ Q05: pointer to constant variable
一个简单的小问题find start point of loop from linked list
请问可以这样定义struct吗?C++ Q93 - Q95 (转载)
is smart_ptr really that good?c++ pointers are iterators, why?
相关话题的讨论汇总
话题: problem话题: coding话题: merging话题: c++话题: pointer