Passing value from function to other function selector

Passing value from function to other function selector

Hi all,
I have issue with passin value between functions:
  1. $(document).ready(function(){
    id = 'test';
         $('#Meno').keyup(function(){
             id = '#Mobil';
         });



  2.  
  3.     $(id).click(function(){
            console.log(id);
         });
    });



I am getting from console.log right value "#Mobil" but $(id) has value "Test". I need there also value "#Mobil".
 Any idea what I am doing wrong?