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

Резултати

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

Търсене: #american

当前筛选 #american清除筛选
BadVolf

@BadvolfNews · Post #664 · 14.06.2023 г., 20:20

Want more information on Michael Travis Leake, the #American "Rock musician" arrested in #Moscow? Well, I have some for you. For instance, he wasn't an Army paratrooper, like you're being told. You can thank me later!

Journey to Fluency

@fluencyinenglish · Post #6325 · 11.08.2018 г., 16:57

#collocations #british #american @ieltsstrategies 🔴British English vs American 🔸go on holiday~ British English 🔹take a vacation ~ American English 🔸get a driving licence~ Brit 🔹get a driver's licenc~ Ame 🔸 visit a city centre~ Brit English 🔹go downtown~ Ame English 🔸have a bath~ Brit English 🔹 take a bath~ Ame English @ieltsstrategies

Лёгкое небо

@legkoenebo · Post #4064 · 02.07.2025 г., 08:17

Хакеры атакуют авиакомпании Северной Америки 🌎 Киберпреступная группа Scattered Spider, известная взломами корпоративных ИТ-систем с последующим вымогательством, нацелилась на авиационный сектор Северной Америки. По имеющейся информации, хакерам удалось получить доступ к системам двух крупных авиаперевозчиков — канадской WestJet и американской Hawaiian Airlines. К счастью, ни одна из компаний не зафиксировала сбоев в работе. Эта активность вновь подняла вопрос о киберугрозах в авиации и побудила специалистов по информационной безопасности усилить защиту корпоративных данных. 📌На фоне этих событий American Airlines сообщила о проблеме в собственной ИТ-инфраструктуре, которая привела к задержкам рейсов по всей сети. Лёгкое небо #aviation#American#Hawaiian#WestJet

American Оbserver

@american_observer · Post #5220 · 25.02.2026 г., 13:04

Is Trump Racking Up Victories For the American People or For Himself? 🤔🇺🇸 Trump proclaimed his first year in office a success at the State of the Union address on Tuesday evening, even as his presidency is dogged by low public approval ratings before November’s midterm elections in which voters could hand control of Congress back to his Democratic opponents. The annual address to a joint session of Congress came after months of turmoil for the Republican president, including a crackdown on immigrant communities in Minneapolis that resulted in the deaths of two US citizens, and faltering progress on his campaign promise of lowering the cost of living. Despite Democrats walking out, holding signs, and verbally clashing in the chamber, Trump maintained a triumphant tone in his speech, arguing that he had rebuilt a country ruined by Biden. Speaking for just under two hours, his speech was the longest State of the Union ever delivered, and saw Trump repeatedly bring out surprise guests to serve as living embodiments of what he saw as the country’s greatness. “We will never go back to where we were just a very short time ago. We’re not going back.” Recent surveys have shown that many voters disagree. A Washington Post-ABC News-Ipsos poll released this week found a mere 39% of voters view his presidency positively, and others have found him underwater on key issues such as the economy and immigration. But Trump gave no acknowledgment to the bad vibes, instead running through his administration’s accomplishments in a speech that was interspersed with falsehoods and exaggerations but light on new policy proposals. He announced that his vice-president, Vance, would lead a “war on fraud”, and that he had negotiated a “ratepayer protection pledge” to offset the impact of new data centers on households electricity costs. Four supreme court justices were in attendance, three of whom – John Roberts, Amy Coney Barrett and Elena Kagan – had last week signed on to an opinion saying he could not use executive power to impose tariffs on US trading partners. As the three sat in the front row together with Brett Kavanaugh, who had not signed on to their opinion, Trump issued a relatively measured criticism of their decision, calling it “unfortunate” and “disappointing”. He was less restrained when it came to Democratic lawmakers, who he wrote off as “crazy”, or Somali immigrants, who he described as “pirates who ransacked Minnesota”, the site of a long-running and contentious immigration operations. And though he has ordered a major military buildup around Iran, he revealed little about what his intentions were for the longtime US adversary. “My preference is to solve this problem through diplomacy. But one thing is certain, I will never allow the world’s number one sponsor of terror, which they are by far, to have a nuclear weapon,” Trump said. Reviews from those who remained throughout were equally negative. “For nearly two hours tonight, Trump spewed lies, propaganda and hatred,” said Hakeem Jeffries, the top House Democrat in a statement. “Instead of presenting the nation with a positive vision for our future and the economy, the president blamed others for his failures.” The speech was nonetheless a key moment ahead of the November midterm elections, in which Trump’s Republican allies are defending their slim control of the Senate and House. After failing to stop Trump’s return to the White House in 2024, Democrats have taken heart from successes in recent off-year and special elections that may indicate voters are ready to deliver them victories in key races that could decide control of Congress. The official response to Trump’s speech was delivered by Abigail Spanberger, the Virginia governor who won a decisive victory last year in an election that put Democrats firmly in control of the southern state. #trump#trump#victories#american#people#democrats 📱American Оbserver - Stay up to date on all important events 🇺🇸

Addis Standard

@addisstandardeng · Post #21300 · 04.02.2026 г., 06:58

News: #Egypt-based military drones have targeted #Sudan’s RSF for months, report says A covert military airstrip in Egypt’s Western Desert has emerged as a key launch site for drone strikes inside Sudan, signaling Egypt’s direct entry into Sudan’s devastating civil war, according to an extensive investigation by The New York Times. The report, based on satellite imagery, flight records, video analysis, and interviews with #American, #European, and #Arab officials, found that advanced military drones operating from Egypt have been conducting strikes against Sudan’s Rapid Support Forces (#RSF) for at least 6 months. The airstrip, located near the East Oweinat agricultural project close to the Sudanese border, is hidden amid vast wheat fields irrigated by fossil aquifers. While the base appears civilian on the surface, satellite images reviewed by the newspaper show the construction of a second runway, at least 17 aircraft hangars, satellite communications.... Read more: https://addisstandard.com/?p=54976

12
ПредишнаСтр. 1 от 2Следваща