返校之厦软
离开厦软已经快一年了,再次返校是拿毕业证。去的人不是很多,我们宿舍当天去的就我和cc鱼。在校园里逛了一会,感觉变化不是很大,厦门还是一如既往的热。
好巧,我们宾馆的房号是206,以前的宿舍房号也是206,和在学校时一样,我们熬夜的毛病还是没改变哈哈。我整个大一的周末有很多是和学长学姐一起度过的,不过毕业后就相隔千里了,哈哈也不知道下次相聚要等多少个春秋了。不得不说两年的时间就像做了梦一样,梦醒了,记忆都是模糊的。
相聚总是短暂的。。。
《清静经》
《清静经》,全称《太上老君说常清静经》 老君曰:大道无形,生育天地;大道无情,运行日月;大道无名,长养万物;吾不知其名,强名曰道。夫道者:有清有浊,有动有静;天清地浊,天动地静;男清女浊,男动女静;降本流末,而生万物。清者,浊之源,动者,静之基;人能常清静,天地悉皆归。
夫人神好清,而心扰之;人心好静,而欲牵之。常能遣其欲,而心自静;澄其心,而神自清;自然六欲不生,三毒消灭。所以不能者,为心未澄,欲未遣也;能遣之者:内观其心,心无其心;外观其形,形无其形;远观其物,物无其物;三者既悟,唯见于空。观空亦空,空无所空;所空既无,无无亦无;无无既无,湛然常寂。寂无所寂,欲岂能生;欲既不生,即是真静。真常应物,真常得性;常应常静,常清静矣。如此清静,渐入真道;既入真道,名为得道;虽名得道,实无所得;为化众生,名为得道;能悟之者,可传圣道。 老君曰:上士无争,下士好争;上德不德,下德执德;执著之者,不名道德。众生所以不得真道者,为有妄心;既有妄心,即惊其神;既惊其神,即著万物;既著万物,即生贪求;既生贪求,即是烦恼;烦恼妄想,忧苦身心;便遭浊辱,流浪生死;常沉苦海,永失真道。真常之道,悟 ...
python爬取一个网页基本内容并保存(上班摸鱼时觉得好玩就cv了)
from urllib import requestfrom ua_info import ua_listimport random
def send_save(filename): url = ‘http://www.smallcolor.top/‘ headers = {‘User-Agent’ : random.choice(ua_list)} req = request.Request(url=url, headers=headers) try: res = request.urlopen(req) if res.geturl() != url: new_url = res.geturl() print(f”Redirected to : {new_url}”) req = request.Request(url=new_url, headers=hea ...
事件循环(event loop)
浏览器进程和线程浏览器采用多进程模型,如网络进程,渲染进程,每个进程都是独立的不相互影响,即使有一个标签页崩溃了其他的也可以正常执行。每个进程又有许多的线程。
渲染线程主要是负责处理和呈现图片的线程。渲染主线程只有一个,js就在它上,同时js是单线程的,就是从前到后执行的那种。同步: 就是按1,2,3这种顺序执行主线程上的任务。异步: 就比如一个setTimeout,或者ajax这种,并不是在主线程上直接执行的,异步出现的原因就是为了让主线程永不堵塞。
微任务: 仅次于主线程,可用Promise.resolve()then(fn()){ }直接将任务变成微任务交互任务: 就是和用户的交互,如按钮的触发。延时任务: 如计时器完成后的任务。优先级: 渲染主线程 > 微任务 > 交互任务 > 延时任务等
总结:JS的运行机制就是事件循环单线程是异步产生的原因事件循环是异步的实现方式
Hello World
关于本站本站为个人博客,属于非盈利性个人网站,博主一人建设并维护。
本站由hexo驱动托管于github pages域名是阿里云买的不要用腾讯!腾讯域名备案很麻烦!一开始不懂还买了个服务器,莫名其妙说我涉黄还给我封了,真想说xxx腾讯!