Below is an instruction that describes a task. Write a response that appropriately completes the request in Chinese. Please answer in Chinese.

### Instruction:
 罐子里有几个饼干。拿走一个饼干会使罐子里剩下的饼干数量是加上5个饼干后的一半。罐子里有多少个饼干？


### Response:
 设C为罐子里的饼干数量。
罐子里会剩下C-1个饼干。
罐子里会剩下(C+5)/2个饼干。
C-1=(C+5)/2。
2*(C-1)=C+5
2C-2=C+5
C=7