2024 年 5 月 1 日 周三 小雨 冷(384 字)

日常生活中的技术困惑与反思:从处方药到信息系统,
文章讲述了作者在日常生活中遇到的技术问题,如寻找处方药、依赖系统的数据验证和旅行中的技术失误,同时也揭示了对技术在生活中的局限性和人性化需求的思考。

正文

  祖父见到我和见长,第一句话是好久都没看到我们的孙子了。然后第二句话直接把我们俩都干懵了。

  “你们有没有阿托品啊?”

  我第一反应是懵,第二反应是想笑。上哪儿给你找这种处方药去…… 这种 M 受体阻断剂管得还严,严重有机磷中毒的时候,一掰就是几十支。而且这药不是最好不用老年人吗,副作用还多,一不小心心跳快高压降不下来…… 治啥啊就想着用阿托品,不会是哪个医生出的馊主意吧。

  早上报表。昨天两点多才睡,今天有点爬不起来。核出来数据感觉有点问题,向上汇报,领导答曰:“相信系统抽数。” 我哭笑不得。

  中午没赶上动车,本来能赶上,我误以为当前排队的是当前车次,结果是下一车次…… 等反应过来一看屏幕已经停止检票了。只能花 40 块去坐汽车了。发车后好像还不能退票了,好气啊。

  坐了一天车,好累。晚上玩了一下死亡细胞,变菜了。

  有些想念她。

  南国微雪 Miyuki

  2024 年 5 月 1 日

封面图

img

本文由博客一文多发平台 OpenWrite 发布!

<template> <view > 经管2201李甜竺202209010120 </view> <view class="container"> <view class="search-bar"> <input v-model="inputCity" placeholder="输入城市名称" @confirm="fetchWeather" /> <button @click="fetchWeather">查询</button> </view> <view class="current-weather"> <view class="city"> {{ city }} </view> <view class="temperature"> {{ realtime.temperature }}℃ </view> <view class="weather-info"> <text>{{ realtime.info }}</text> </view> <view class="current-weather"> <view class="current-aqi"> <text class="aqi-number">{{realtime.aqi}}–{{computeAirQuality}}</text> <view class="progress-box"> <progress :percent="20" activeColor="#FFFFFF" backgroundColor="#10AEFF" stroke-width="3"/> </view> <text class="aqi-info">当前AQI(CN)为{{realtime.aqi}}。</text> </view> </view> <view class="future"> <view class="future-item" v-for="(item,index) in future" :key="index"> <view class="future-item-left"> <view class="timer">{{getDay(item.date)}}</view> <view class="weekDay">{{getWeekday(item.date)}}</view> </view> <image :src="getWeather(item.weather)" mode=""></image> <view class="future-temperature">{{item.temperature}}</view> </view> </view> <view class="other"> <view class="humidity"> <view class="other-title"> <span class="iconfont"></span> <text>湿度</text> </view> <view class="other-number mt26">{{realtime.humidity}}%</view> <view class="other-info mt26">舒适度:{{computeComfort}}</view> </view> <view class="demeanor"> <view class="other-title"> <span class="iconfont"></span> <text>风度</text> </view> <view class="other-number">{{ realtime.power }}</view> <view class="other-info">风力:{{realtime.direct}}</view> </view> </view> <view class="life-recommend" style="margin-top: 26rpx;"> <text>生活建议</text> <view class="cutting-line mt26"></view> <view class="category mt26"> <view class="category-item" v-for="(value,key,index) in life" :key="index"> <rich-text :nodes="lifeIconfontList[key]"></rich-text> <view class="item-descript">{{value.v}}</view> </view> </view> </view> </view> </view> </template> <script> import { getInfo } from"@/api/info.js" export default { onLoad(){ this.getWeathers(); this.getLife(); }, data() { return { inputCity:"", city: "西安", realtime: { "temperature": "10", "humidity": "100", "info": "阴", "wid": "02", "direct": "东风", "power": "1级", "aqi": "56" }, "future":[{ "date": "2025-10-23", "temperature": "8/16℃", "weather": "多云", "wid": { "day": "01", "night": "01" }, "direct": "西风转东北风" }, { "date": "2025-10-24", "temperature": "8/12℃", "weather": "小雨", "wid": { "day": "07", "night": "07" }, "direct": "东北风转西南风" }, { "date": "2025-10-25", "temperature": "5/17℃", "weather": "多云", "wid": { "day": "01", "night": "01" }, "direct": "西风转东北风" }, { "date": "2025-10-26", "temperature": "7/19℃", "weather": "多云", "wid": { "day": "01", "night": "01" }, "direct": "东北风" }, { "date": "2025-10-27", "temperature": "7/15℃", "weather": "多云", "wid": { "day": "01", "night": "01" }, "direct": "东北风转西风" }], weatherIconList: [ "/static/weather/sun.bmp", "/static/weather/overcast.bmp", "/static/weather/cloudy.bmp", "/static/weather/rain.bmp", ], standardList:["优","良","轻度污染","中度污染","重度污染","严重污染"], lifeIconfontList: { "kongtiao": '<span class="iconfont"></span>', "guomin": '<span class="iconfont"></span>', "shushidu": '<span class="iconfont"></span>', "chuanyi": '<span class="iconfont"></span>', "diaoyu": '<span class="iconfont"></span>', "ganmao": '<span class="iconfont"></span>', "ziwaixian": '<span class="iconfont"></span>', "xiche": '<span class="iconfont"></span>', "yundong": '<span class="iconfont"></span>', "daisan": '<span class="iconfont"></span>' }, life: { "kongtiao": { "v": "较少开启", "des": "您将感到很舒适,一般不需要开启空调。" }, "guomin": { "v": "极不易发", "des": "天气条件极不易诱发过敏。" }, "shushidu": { "v": "较舒适", "des": "白天天气晴好,您在这种天气条件下,会感觉早晚凉爽、舒适,午后偏热。" }, "chuanyi": { "v": "较", "des": "建议着厚外套加毛衣等服装。老体弱者宜着大衣、呢外套加羊毛衫。" }, "diaoyu": { "v": "不宜", "des": "天气不好,不适合垂钓。" }, "ganmao": { "v": "极易发", "des": "天气条件极易诱发感冒,请注意适当增减衣服,加强自我防护避免感冒。" }, "ziwaixian": { "v": "最弱", "des": "属弱紫外线辐射天气,无需特别防护。若长期在户外,建议涂擦SPF在8-12之间的防晒护肤品。" }, "xiche": { "v": "较适宜", "des": "较适宜洗车,未来一天无雨,风力较小,擦洗一新的汽车至少能保持一天。" }, "yundong": { "v": "较适宜", "des": "天气较好,无雨水困扰,较适宜进行各种运动,但因气温较低,在户外运动请注意增减衣物。" }, "daisan": { "v": "不带伞", "des": "天气晴好,您在这种天气条件下,无需带伞。" } } }; }, methods: { // 新增:查询天气方法 async fetchWeather() { const city = this.inputCity.trim(); if (!city) { uni.showToast({ title: "请输入城市", icon: "none" }); return; } // 调用聚合数据API查询天气 const apiKey = "27721abb4ebff0b3cd292d750479cd1d"; const timestamp = new Date().getTime(); const url = `https://apis.juhe.cn/simpleWeather/query?city=${encodeURIComponent(this.inputCity)}&key=${apiKey}`; try { const res = await uni.request({ url, method: "GET" }); if (res[1].error_code === 0) { this.city = res[1].result.realtime.city; this.realtime = res[1].result.realtime; // 更新实时数据 this.future = res[1].result.future; // 更新未来期数据 }else{ console.log("天气查询失败:", res.data.reason); uni.showToast({ title: "查询失败,请稍后重试", icon: "none" }); } } catch (err){ console.error("天气查询失败:", err); uni.showToast({ title: "网络或API异常", icon: "none" }); } }, // 新增:查询生活建议(若需要) async fetchLifeSuggestion() { const city = this.inputCity.trim(); const timestamp = new Date().getTime(); const apiKey = "27721abb4ebff0b3cd292d750479cd1d"; const url = `https://apis.juhe.cn/simpleWeather/life?city=${encodeURIComponent(this.inputCity)}&key=${apiKey}`; try { const res = await uni.request({ url, method: "GET" }); if (res.data && res.data.error_code === 0) { this.life = res[1].result.life; }else{ console.log("生活建议查询失败:", res[1].reason); } } catch (err) { console.error("生活建议查询失败:", res.data.reason); } }, getWeekday(date) { let weekdays = ["周", "周一", "周二", "周三", "周四", "周五", "周六"]; let weekday = new Date(date).getDay(); return weekdays[weekday]; }, getDay(date) { let newDate=date.split("-")[1]+""+date.split("-")[2]+"" return newDate }, getWeather(status) { let src = ""; switch (status) { case "晴": src = this.weatherIconList[0]; break; case "阴": src = this.weatherIconList[1]; break; case "多云": src = this.weatherIconList[2]; break; case "小雨": src = this.weatherIconList[3]; break; case "多云转阴": src = this.weatherIconList[1]; break; case "多云转晴": src = this.weatherIconList[2]; break; case "小雨转阴": src = this.weatherIconList[3]; break; default: } return src; }, getWeathers(){ let param ={ URL: "/juhe/simpleWeather/query", Method:"GET", Params:[{ Key:"key", Value:"27721abb4ebff0b3cd292d750479cd1d" }, { Key:"city", Value:"西安" }] } getInfo(param).then(res=>{ //this.realtime = JSON.parse(res.data).result.realtime //this.future = JSON.parse(res.data).result.future }).catch(err => { console.log('请求天气数据错误详情:', err); }) }, getLife(){ let data ={ URL:"/juhe/simpleWeather/life", Method:"GET", Params:[{ Key:"key", Value:"27721abb4ebff0b3cd292d750479cd1d", }, { Key:"city", Value:"西安" }] } getInfo(data).then(res =>{ //this.life = JSON.parse(res.data).result.life }).catch(err => { console.log('请求生活建议数据错误:', err); uni.showToast({ title: '天气数据请求失败,请检查网络或API配置', icon: 'none' }); }) } }, computed: { computeAirQuality() { // 空气情况 let data = Number(this.realtime.aqi); if (data <= 50) { return this.standardList[0]; } else if (50 < data && data <= 100) { return this.standardList[1]; } else if (100 < data && data <= 150) { return this.standardList[2]; } else if (150 < data && data <= 200) { return this.standardList[3]; } else if (200 < data && data <= 300) { return this.standardList[4]; } else { return this.standardList[5]; } }, computeComfort() { let comfortLevel = ["极度干燥", "偏干", "舒适", "略湿润", "湿润", "非常潮湿"]; let humidity = Number(this.realtime.humidity); if (humidity <= 30) { return comfortLevel[0]; } else if (humidity > 30 && humidity <= 40) { return comfortLevel[1]; } else if (humidity > 40 && humidity <= 60) { return comfortLevel[2]; } else if (humidity > 60 && humidity <= 70) { return comfortLevel[3]; } else if (humidity > 70 && humidity <= 85) { return comfortLevel[4]; } else { return comfortLevel[5]; } }, }, }; </script> <style scoped lang="scss"> .container { background-size: cover; height: 100vh; color: white; overflow-y: scroll; background-image: url("/static/weather/morning.jpg"); } .current-weather { text-align: center; margin-bottom: 30rpx; .city { font-size: 50rpx; line-height: 50rpx; } .temperature { font-size: 110rpx; line-height: 130rpx; } .weather-info { font-size: 36rpx; margin-bottom: 100rpx; } .current-aqi { box-sizing: border-box; width: 90%; border-radius: 30rpx; margin: auto; margin-bottom: 26rpx; padding: 30rpx; background-color: rgba(255, 255, 255, 0.1); .aqi-number { font-size: 36rpx; } .progress-box { margin: 20rpx 0; } } } .future { box-sizing: border-box; width: 90%; border-radius: 30rpx; margin: auto; margin-bottom: 26rpx; padding: 30rpx; background-color: rgba(255, 255, 255, 0.1); .future-item { display: flex; align-items: center; justify-content: space-between; .future-item-left { display: flex; .timer { margin-right: 20rpx; } } image { width: 50rpx; height: 50rpx; } .future-temperature { width: 100rpx; } } } .other { box-sizing: border-box; width: 90%; margin: 0 auto; display: flex; justify-content: space-between; .humidity, .demeanor { box-sizing: border-box; width: 48%; padding: 20rpx; border-radius: 30rpx; background-color: rgba(255, 255, 255, 0.1); .other-title { color: rgba(255, 255, 255, 0.5); .iconfont { margin-right: 10rpx; } } .other-info { color: rgba(255, 255, 255, 0.9); } .other-number { font-size: 55rpx; } .mt26 { margin-top: 26rpx; } } } .life-recommend { box-sizing: border-box; width: 90%; border-radius: 30rpx; margin: 0 auto; padding: 30rpx; background-color: rgba(255, 255, 255, 0.1); text { font-size: 32rpx; font-weight: bold; } .cutting-line { height: 1px; background-color: #fcfcfc; margin: 26rpx 0; } .category { display: flex; flex-wrap: wrap; .category-item { width: 33%; height: 140rpx; display: flex; flex-direction: column; align-items: center; justify-content: center; .iconfont { font-size: 50rpx; } .item-descript { margin-top: 10rpx; font-size: 28rpx; } } } } .search-bar { display: flex; gap: 20rpx; padding: 20rpx; background-color: rgba(255, 255, 255, 0.1); border-radius: 16rpx; margin: 20rpx; } input { flex: 1; border: 1px solid #eee; border-radius: 8rpx; padding: 16rpx; color: #fff; } button { background: #007dff; color: #fff; border: none; border-radius: 8rpx; padding: 0 32rpx; } </style>不能实时更新天气
11-15
基于模拟退火的计算器 在线运行 访问run.bcjh.xyz。 先展示下效果 https://pan.quark.cn/s/cc95c98c3760 参见此仓库。 使用方法(本地安装包) 前往Releases · hjenryin/BCJH-Metropolis下载最新 ,解压后输入游戏内校验码即可使用。 配置厨具 已在2.0.0弃用。 直接使用白菜菊花代码,保留高级厨具,新手池厨具可变。 更改迭代次数 如有需要,可以更改 中39行的数来设置迭代次数。 本地编译 如果在windows平台,需要使用MSBuild编译,并将 改为ANSI编码。 如有条件,强烈建议这种本地运行(运行可加速、可多次重复)。 在 下运行 ,是游戏中的白菜菊花校验码。 编译、运行: - 在根目录新建 文件夹并 至build - - 使用 (linux)(windows) 运行。 最后在命令行就可以得到输出结果了! (注意顺序)(得到厨师-技法,表示对应新手池厨具) 注:linux下不支持多任务选择 云端编译已在2.0.0弃用。 局限性 已知的问题: - 无法得到最优解! 只能得到一个比较好的解,有助于开阔思路。 - 无法选择菜品数量(默认拉满)。 可能有一定门槛。 (这可能有助于防止这类辅助工具的滥用导致分数膨胀? )(你问我为什么不用其他语言写? python一个晚上就写好了,结果因为有涉及json读写很多类型没法推断,jit用不了,算这个太慢了,所以就用c++写了) 工作原理 采用两层模拟退火来最大化总能量。 第一层为三个厨师,其能量用第二层模拟退火来估计。 也就是说,这套方法理论上也能算厨神(只要能够在非常快的时间内,算出一个厨神面板的得分),但是加上厨神的食材限制工作量有点大……以后再说吧。 (...
<think>好的,我需要确定202451是第几周。首先,得明确周的计算标准,因为不同地区可能有不同的周开始,比如有的从周开始,有的从周一开始。根据国际标准ISO 8601,通常将周一作为一周的第一天,一中的第一周是包含第一个星期四的那周,也就是至少有四天在当。 接下来,查找2024历。2024是闰11是星期一。按照ISO标准,第一周从11开始,因为这一天是周一,且包含了第一个星期四(14)。因此,1117是第一周。 然后计算到51的周数。1有31天,229天,331天,430天。到430的总天数是31+29+31+30=121天。加上51就是122天。每周7天,122除以7得17周余3天。所以51是在第18周。但需要确认具体期对应的周数,可能根据计算方式不同有差异。 验证时发现,有些历系统可能将11算作第1周,而ISO标准下可能略有不同。比如,202411是周一,根据ISO,第一周是包含新第一个周四的周,这里14是周四,所以第一周从11开始。因此,51确实是第18周的第3天(周三)。需要确认不同来源是否有不同结果,可能存在差异,但大多数情况下按照ISO标准是第18周。</think>根据国际标准ISO 8601周数计算规则(以**周一作为每周起始**),202451属于**第18周**。具体分析如下: 1. **202411(周一)属于第1周** ISO标准规定:每第一个包含周四的周为第1周。由于202414是周四,因此包含该的周(11-17)被定义为第1周。 2. **期累计天数计算** 截至202451总天数为: $31\ (1) + 29\ (2) + 31\ (3) + 30\ (4) + 1\ (51) = 122\ 天$ 换算为周数: $\frac{122}{7} \approx 17.43$,向上取整为**第18周**。 3. **编程验证方法** 使用Python代码可快速验证周数: ```python from datetime import datetime date = datetime(2024, 5, 1) week_number = date.isocalendar()[1] print(week_number) # 输出结果为18 ```
评论
成就一亿技术人!
拼手气红包6.0元
还能输入1000个字符
 
红包 添加红包
表情包 插入表情
 条评论被折叠 查看
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值