There is some misunderstanding between me and Scala

**0 or 1?**

```
object Fun extends App {

 def foo(list:List[Int], count:Int = 0): Int = {

    if (list.isEmpty) { // when this is true
      return 1   // and we are about to return 1, the code goes to the next line
    }

    foo(list.tail, count + 1) // I know I do not use "return here" ...

    count
  }

  val result = foo( List(1,2,3) )

  println ( result ) // 0

}

```

1. Why does it print 0?
2. Why does recursion work even without "return"
(when it is in the middle of function, but not in the end)?
3. Why doesn't it return 1? when I use "return" explicitly?

**--- EDIT:**

It will work if I use `return` here `"return foo(list.tail, count + 1)'`.
Bu it does NOT explain (for me) why "return 1" does not work above.