How long they lay for depends on a lot of things - Rosemary can probably be more specific, but in my experience it's influenced by the age they started to lay, the breed, the conditions they live in, amount of light, feeding etc. Sorry but you asked the length of a piece of string.
I don't kill mine - I leave them to enjoy life to the end (unless they look really poorly, but even then I'm reluctant as I've seen them recover when apparently on their last wings)- chickens can be fine one day and dead when you go into the shed the next.
Also, they can lay sporadically - depends what you want to do - keep a chicken only as long as it lays every day - then kill it if you want food. Mine all have personalities so basically they are my pets as well as my food source (eggs and manure for the veg only though). I have said before I'll eat anything except my own animals
Not much help to you but I'm sure others will give you better replies
Annie