class XXX { void foo() { int k = 0; int n = 2; Runnable r = ()->{ k = n; }; } }