TGTGInsightтелеграм анализLIVE / telegram public index
← Такты, стеки, два колеса

TGINSIGHT SIMILAR POSTS

Намери подобно съдържание

Изходен канал @clockstackwheels · Post #721 · 26.12

Почему я люблю языки с сильной системой типов, проверяемой статическим анализом кода — хорошо написанная программа является своей собственной спецификацией и позволяет выражать через язык программирования законы существования предметной области. Когда-то давно я писал на ActionScript. Там была система типов, но вот десериализация JSON'ов по-умолчанию была в какой-то общий Object, к полям которого нужно было обращаться ["по_строковому_имени"]. В один момент мне потребовалось написать что-то на C#, который я совсем не знал, я стал гуглить, как десериализовать JSON, и с удивлением обнаружил кучу советов заранее объявить класс со всеми нужными полями и десериализовать в него. "Какой ужас!", — подумал я тогда, — "Это же дико неудобно! А если я не знаю полей JSON? А если их много? Отвратительный язык!" Теперь то я прекрасно понимаю, что JSON это контракт, и что правильная десериализация только такая и должна быть, и что в хорошем API в одном поле никогда не бывает данных принципиально разных типов, и так далее. Нет, если вы набиваете вечерами пет-проект или сидите бессонную ночь на хакатоне, нет ничего плохого в том, чтобы взять простой язык с динамическими типами вроде JavaScript или Python, не требующий описывать данные. Но вот в энтерпрайзе, особенно когда над одним проектом работает много людей (а бывает это очень часто) — хорошее использование системы типов убережёт разработчиков от огромного количества ошибок, будет бить их по рукам, когда они пытаются сделать что-то не то, и будет подсказывать, когда они не уверены в чём-то. С помощью статической типизации можно на уровне кода обозначить правила, по которым ведёт себя предметная область вашей программы в реальном мире. Разработчику не только будет сложно их нарушить, но он ещё и станет узнавать какие-то вещи, которые мог не знать раньше. Например, если мы делаем медицинскую CRM, и больница заводит новых пациентов только тогда, когда знает их группу крови, мы можем объявить тип "Пациент" (или, если точнее, "Карта пациента") и запретить создавать экземпляры этого типа, не передав в конструктор группу крови (которая, в свою очередь, тоже является типом, вероятнее всего ValueObject'ом). Если новый программист пришёл в проект, он, во-первых, не сможет записать в БД некорректную карту пациента. Понятно, мы не учитываем случаи, когда новый программист переделывает модели предметной области — это будет хорошо видно на кодревью. А, во-вторых, даже если ему никто не сказал, что пациенты должны быть с группой крови, он узнает это из кода. И уже будет понимать, что в тех процессах реальной жизни, которые он описывает кодом, карта пациента создаётся только при наличии группы крови. А, значит, нужно искать какой-то способ сначала эту группу крови получить, и только потом создавать карту. Программирование моделирует реальный процесс. В настоящей работе даже на языках с типами, конечно, без должного контроля можно написать что угодно. Нужна управленческая воля, компетентность руководства, понимание опасности техдолга, в идеале отдельные должности для архитекторов, опытные лиды и старшие разработчики. Но когда всё это есть, можно отсекать много проблем ещё на старте и проще погружать новичков. #dev

Hashtags

Резултати

Намерени 204 подобни публикации

Търсене: #mufc

当前筛选 #mufc清除筛选
Manchester United⚽💯

@manchester_utdfc · Post #115159 · 15.05.2026 г., 14:16

Matthijs de Ligt: “Since November I have done everything, pushing myself in every session and exploring every option, to get back to doing what I love, playing football. “I am grateful to everyone who has supported me throughout a difficult period in my career. I remain as determined as ever to represent Manchester United and play in front of our incredible supporters as soon as possible.” #MUFC [MU]

Hashtags

Manchester United⚽💯

@manchester_utdfc · Post #115158 · 15.05.2026 г., 14:12

Matthijs de Ligt Ig: “After 6 months of treatment and working hard to get back, surgery was the only option left. I’m disappointed I couldn’t help the team the last 6 months and obviously missing out on the World Cup but I am looking forward to doing everything to get back in front of the fans and feeling better again 🙏🏼💪🏼” #MUFC

Hashtags

Manchester United⚽💯

@manchester_utdfc · Post #115157 · 15.05.2026 г., 14:11

Matthijs de Ligt has undergone successful surgery to adress a back injury, say Manchester United. They say De Ligt will begin a new phase of his recovery and is expected to return for United in the early stages of the 2026/27 season. #MUFC

Hashtags

Manchester United⚽💯

@manchester_utdfc · Post #115155 · 15.05.2026 г., 13:14

Michael Carrick on #mufc's future targets: "You’ve got to aim upwards. That’s the beauty of football, beauty of competition to achieve something and back it up, that’s the challenge. "For the players, for the squad, for the whole group and football club we want to keep moving in a positive way and in the right direction. "The closer you get to the top the less room for progress, but progress is what we’re aiming for."

Hashtags

Manchester United⚽💯

@manchester_utdfc · Post #115148 · 15.05.2026 г., 11:09

Jamie Carragher on his ‘leave football before it leaves you’ comments on Casemiro: “In retrospect, do I regret my comments about such a legendary footballer? Yes and no. It must be acknowledged that the implication that Casemiro was 'finished' at the highest level was too harsh and premature. “My argument was he would be better heading out to the MLS, or accepting offers from Saudi Arabia, because he would never get back to anywhere near his best to achieve the same heights of winning the Champions League or league titles at Old Trafford as he did so brilliantly at Real Madrid. “At the time, those observations were not controversial. In 2024, Casemiro was unfit, lacked the physicality and athleticism to cope with quicker, sharper opponents, and was exposed when used in a deeper role, either in midfield or at centre-back as he was that night at Selhurst Park. “This week, Casemiro suggested my remarks were 'disrespectful', and that is fair enough. Anything he says in response comes with the territory, although I would counter and say no disrespect was intended. Quite the contrary. “Because of his stellar career, it was natural to compare Casemiro to the extraordinarily high standards he set for himself.” #MUFC [Telegraph] 📥@Manchester_Utdfc

Hashtags

Manchester United⚽💯

@manchester_utdfc · Post #115143 · 15.05.2026 г., 10:51

🚨 Manchester United are proposing an initial TWO-YEAR contract offer to Michael Carrick until 2028! Talks are now underway after co-owner Sir Jim Ratcliffe gave the go-ahead following an executive committee meeting this week where chief executive Omar Berrada and director of football Jason Wilcox made the recommendation for Carrick to get the job full-time 🔴 [Laurie Whitwell, The Athletic] #mufc 📥@Manchester_Utdfc

Hashtags

Manchester United⚽💯

@manchester_utdfc · Post #115142 · 15.05.2026 г., 10:46

Michael Carrick’s backroom staff are expected to stay, with Steve Holland, Jonathan Woodgate and Jonny Evans all in line for new deals. Craig Mawson is also set to continue as first-team goalkeeping coach following his promotion after Ruben Amorim’s departure. #mufc also want to add a set-piece coach, with Andreas Georgson, highly rated during his previous spell at United, among the contenders to return from Tottenham [Laurie Whitwell] 📥@Manchester_Utdfc

Hashtags

Manchester United⚽💯

@manchester_utdfc · Post #115132 · 14.05.2026 г., 13:41

Excl: #MUFC plan to offer Michael Carrick an initial contract of 2 years until June 2028 with a 1 year option to extend. No formal negotiations have begun so no agreement yet. The 44 yo has been involved in recruitment meetings for the summer. [Sully Talkz] 📥@Manchester_Utdfc

Hashtags

123•••10•••1617
ПредишнаСтр. 1 от 17Следваща