---
# System prepended metadata

title: pointer練習2

---

# pointer練習2
https://neoj.sprout.tw/problem/168/
int* min(int* a,int* b);

只需要把最小值(a和b)的位址傳回去即可。
# Code
```cpp
int* min(int* a, int* b)
{
  if (*a < *b)
  {
    return a;
  }
  else
  {
    return b;
  }
}
```