# Function return notation.

**URL:** <https://forum.kx.com/t/function-return-notation/12453>\
**Category:** Community Support\
**Tags:** kdb-and-q\
**Created:** [March 17, 2022, 6:29pm UTC](https://forum.kx.com/t/function-return-notation/12453 "2022-03-17T18:29:00Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![PTECH1271](https://avatars.discourse-cdn.com/v4/letter/p/2acd7d/32.png) [@PTECH1271](https://forum.kx.com/u/PTECH1271)\
**Post date:** [March 17, 2022, 6:29pm UTC](https://forum.kx.com/t/function-return-notation/12453/1 "2022-03-17T18:29:00Z")

</div>

Why does addition return 0w?

Why does multiplication return 0n?

?

---

<div class="post-metadata">

**Author:** ![SJT1](https://avatars.discourse-cdn.com/v4/letter/s/eb8c5e/32.png) [@SJT1](https://forum.kx.com/u/SJT1)\
**Post date:** [March 18, 2022, 7:32am UTC](https://forum.kx.com/t/function-return-notation/12453/2 "2022-03-18T07:32:00Z")

</div>

Two expressions: one multiplies `0+0` by `1%0&0`; the other adds them.&nbsp;

The sum of two long zeros is long zero.

`1%0` is float infinity `0w`. The type of the right argument does not matter; Divide always returns a float.&nbsp;

So the comparison is between `0*0w` and `0+0w`.&nbsp;

The latter is `0w`. Surely expected: infinity plus `x` is infinity.

The unexpected result then is `0*0w`. Is not `0*x` always zero? But here its a float null `0n`. I do not know the mathematical justification for this; perhaps someone else can shed light?

BTW your lambdas could be simpler:

&nbsp;

test1:{(x+y)\*1%x&y} test2:{(x+y)+1%x&y}

&nbsp;

&nbsp;

&nbsp;

&nbsp;
