Home > Backend Development > PHP Tutorial > 关于秒杀程序设计解决思路

关于秒杀程序设计解决思路

WBOY
Release: 2016-06-13 12:33:13
Original
1007 people have browsed it

关于秒杀程序设计
目前的想法是这样:

      当用户参与秒杀后 把所有用户插入数据库,然后按时间轮询 直到计时器为零的时候 轮询到哪一个,这个就是中秒杀者,
      轮询时间是一秒  ,问题是 如果 到最后一秒时候 又有用户按秒杀,这时候 到让计数器加时,然后继续轮询 ,
      不知道何不合理!!!

    请各位 各抒起见! 谢谢

Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template