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

Резултати

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

Търсене: #gazastrip

当前筛选 #gazastrip清除筛选
Marwa Osman/MidEaStream

@Marwa_OsmanLB · Post #3977 · 06.02.2025 г., 14:56

In an unprecedented move following his shock proposal for the permanent resettlement of the more than two million Palestinians from Gaza to neighboring countries, President Donald Trump announced a controversial plan for the U.S. to take over the Gaza Strip. This statement, made during a press conference with Israeli PM Benjamin Netanyahu, raised eyebrows worldwide. A journalist cornered Trump so he sought Bibi’s help to complete his answer. #UnitedStates#Israel#DonaldTrump#BenjaminNetanyahu#GazaStrip

🎙Commentary by Aide to the President of Russia YuryUshakov following a telephone conversation between Vladimir Putin and President of the United States Donald Trump (October 16, 2025) 💬Yury Ushakov: Today in the afternoon, Vladimir Putin had a telephone conversation, the eighth one, with US President Donald Trump. The conversation lasted almost two and a half hours. Clearly, it was a rather substantive and at the same time very open and frank exchange. Our President started out by congratulating Donald Trump on his successful efforts to normalise the situation in the #GazaStrip. The US President’s peace work has been duly appreciated in the #MiddleEast, in the United States itself, and in most countries around the world. Naturally, the Russian Side outlined its principled position in favour of a comprehensive Middle East settlement on a generally recognised international legal basis that would ensure lasting peace for all the peoples in that region. A special emphasis during the conversation was placed on the #UkraineCrisis. ❗️ Vladimir Putin provided a detailed assessment of the current situation, stressing Russia’s interest in achieving a peaceful resolution through political and diplomatic methods. In particular, it was noted that during the special military operation, the Russian Armed Forces hold full strategic initiative along the entire line of contact. Under these circumstances, the Kiev regime resorts to terrorist methods, attacking civilian targets and energy infrastructure facilities, to which we are forced to respond accordingly. *** Donald Trump repeatedly emphasised the imperative of establishing peace in Ukraine at the earliest opportunity. The notion that the Russian-Ukrainian conflict has proven the most intractable issue in all peacekeeping efforts of the US President was palpably evident throughout his remarks during the conversation. In this context, he naturally mentioned his successes in settling eight other regional conflicts. It is noteworthy that one of the US President’s key arguments centred on the premise that the resolution of the conflict in Ukraine would open up tremendous — and he stressed this — tremendous prospects for the development of US-Russian economic cooperation. Incidentally, both Sides spoke of the profound mutual affinity between the peoples of the two countries, which was so vividly demonstrated during #WWII. It was underscored that the current state of bilateral relations appears paradoxical against this backdrop. The issue of potential supplies of long-range Tomahawk cruise missiles to Ukraine was also raised. Vladimir Putin reiterated his position that Tomahawks would not change the situation on the battlefield but would inflict substantial damage to relations between our countries, to say nothing of the prospects for a peaceful settlement. In this context, it is worthy of note that the Presidents discussed the possibility of holding another personal meeting. This is indeed a very significant development. It was agreed that representatives of both countries would immediately begin preparations for the Summit, which could potentially be organised in Budapest, for instance. On a separate note, it should be mentioned that our President highly praised personal efforts of the First Lady of the United States Melania Trump in reuniting Russian and Ukrainian children with their families and asked the US President to convey his very best wishes to his spouse. Overall, I would say that the telephone contact between the Presidents of Russia and the United States was quite useful, and the two Leaders agreed to maintain contact. 🇷🇺🇺🇸#RussiaUS

Россия в ОБСЕ

@RusMissionOSCE · Post #7506 · 16.10.2025 г., 22:36

🎙Commentary by Aide to the President of Russia YuryUshakov following a telephone conversation between Vladimir Putin and President of the United States Donald Trump (October 16, 2025) 💬Yury Ushakov: Today in the afternoon, Vladimir Putin had a telephone conversation, the eighth one, with US President Donald Trump. The conversation lasted almost two and a half hours. Clearly, it was a rather substantive and at the same time very open and frank exchange. Our President started out by congratulating Donald Trump on his successful efforts to normalise the situation in the #GazaStrip. The US President’s peace work has been duly appreciated in the #MiddleEast, in the United States itself, and in most countries around the world. Naturally, the Russian Side outlined its principled position in favour of a comprehensive Middle East settlement on a generally recognised international legal basis that would ensure lasting peace for all the peoples in that region. A special emphasis during the conversation was placed on the #UkraineCrisis. ❗️ Vladimir Putin provided a detailed assessment of the current situation, stressing Russia’s interest in achieving a peaceful resolution through political and diplomatic methods. In particular, it was noted that during the special military operation, the Russian Armed Forces hold full strategic initiative along the entire line of contact. Under these circumstances, the Kiev regime resorts to terrorist methods, attacking civilian targets and energy infrastructure facilities, to which we are forced to respond accordingly. *** Donald Trump repeatedly emphasised the imperative of establishing peace in Ukraine at the earliest opportunity. The notion that the Russian-Ukrainian conflict has proven the most intractable issue in all peacekeeping efforts of the US President was palpably evident throughout his remarks during the conversation. In this context, he naturally mentioned his successes in settling eight other regional conflicts. It is noteworthy that one of the US President’s key arguments centred on the premise that the resolution of the conflict in Ukraine would open up tremendous — and he stressed this — tremendous prospects for the development of US-Russian economic cooperation. Incidentally, both Sides spoke of the profound mutual affinity between the peoples of the two countries, which was so vividly demonstrated during #WWII. It was underscored that the current state of bilateral relations appears paradoxical against this backdrop. The issue of potential supplies of long-range Tomahawk cruise missiles to Ukraine was also raised. Vladimir Putin reiterated his position that Tomahawks would not change the situation on the battlefield but would inflict substantial damage to relations between our countries, to say nothing of the prospects for a peaceful settlement. In this context, it is worthy of note that the Presidents discussed the possibility of holding another personal meeting. This is indeed a very significant development. It was agreed that representatives of both countries would immediately begin preparations for the Summit, which could potentially be organised in Budapest, for instance. On a separate note, it should be mentioned that our President highly praised personal efforts of the First Lady of the United States Melania Trump in reuniting Russian and Ukrainian children with their families and asked the US President to convey his very best wishes to his spouse. Overall, I would say that the telephone contact between the Presidents of Russia and the United States was quite useful, and the two Leaders agreed to maintain contact. 🇷🇺🇺🇸#RussiaUS

Russian Embassy in Cambodia

@russian_embassy_in_cambodia · Post #5317 · 17.10.2025 г., 02:09

🎙Commentary by Aide to the President of Russia YuryUshakov following a telephone conversation between Vladimir Putin and President of the United States Donald Trump (October 16, 2025) 💬Yury Ushakov: Today in the afternoon, Vladimir Putin had a telephone conversation, the eighth one, with US President Donald Trump. The conversation lasted almost two and a half hours. Clearly, it was a rather substantive and at the same time very open and frank exchange. Our President started out by congratulating Donald Trump on his successful efforts to normalise the situation in the #GazaStrip. The US President’s peace work has been duly appreciated in the #MiddleEast, in the United States itself, and in most countries around the world. Naturally, the Russian Side outlined its principled position in favour of a comprehensive Middle East settlement on a generally recognised international legal basis that would ensure lasting peace for all the peoples in that region. A special emphasis during the conversation was placed on the #UkraineCrisis. ❗️ Vladimir Putin provided a detailed assessment of the current situation, stressing Russia’s interest in achieving a peaceful resolution through political and diplomatic methods. In particular, it was noted that during the special military operation, the Russian Armed Forces hold full strategic initiative along the entire line of contact. Under these circumstances, the Kiev regime resorts to terrorist methods, attacking civilian targets and energy infrastructure facilities, to which we are forced to respond accordingly. *** Donald Trump repeatedly emphasised the imperative of establishing peace in Ukraine at the earliest opportunity. The notion that the Russian-Ukrainian conflict has proven the most intractable issue in all peacekeeping efforts of the US President was palpably evident throughout his remarks during the conversation. In this context, he naturally mentioned his successes in settling eight other regional conflicts. It is noteworthy that one of the US President’s key arguments centred on the premise that the resolution of the conflict in Ukraine would open up tremendous — and he stressed this — tremendous prospects for the development of US-Russian economic cooperation. Incidentally, both Sides spoke of the profound mutual affinity between the peoples of the two countries, which was so vividly demonstrated during #WWII. It was underscored that the current state of bilateral relations appears paradoxical against this backdrop. The issue of potential supplies of long-range Tomahawk cruise missiles to Ukraine was also raised. Vladimir Putin reiterated his position that Tomahawks would not change the situation on the battlefield but would inflict substantial damage to relations between our countries, to say nothing of the prospects for a peaceful settlement. In this context, it is worthy of note that the Presidents discussed the possibility of holding another personal meeting. This is indeed a very significant development. It was agreed that representatives of both countries would immediately begin preparations for the Summit, which could potentially be organised in Budapest, for instance. On a separate note, it should be mentioned that our President highly praised personal efforts of the First Lady of the United States Melania Trump in reuniting Russian and Ukrainian children with their families and asked the US President to convey his very best wishes to his spouse. Overall, I would say that the telephone contact between the Presidents of Russia and the United States was quite useful, and the two Leaders agreed to maintain contact. 🇷🇺🇺🇸#RussiaUS

🎙Commentary by Aide to the President of Russia YuryUshakov following a telephone conversation between Vladimir Putin and President of the United States Donald Trump (October 16, 2025) 💬Yury Ushakov: Today in the afternoon, Vladimir Putin had a telephone conversation, the eighth one, with US President Donald Trump. The conversation lasted almost two and a half hours. Clearly, it was a rather substantive and at the same time very open and frank exchange. Our President started out by congratulating Donald Trump on his successful efforts to normalise the situation in the #GazaStrip. The US President’s peace work has been duly appreciated in the #MiddleEast, in the United States itself, and in most countries around the world. Naturally, the Russian Side outlined its principled position in favour of a comprehensive Middle East settlement on a generally recognised international legal basis that would ensure lasting peace for all the peoples in that region. A special emphasis during the conversation was placed on the #UkraineCrisis. ❗️ Vladimir Putin provided a detailed assessment of the current situation, stressing Russia’s interest in achieving a peaceful resolution through political and diplomatic methods. In particular, it was noted that during the special military operation, the Russian Armed Forces hold full strategic initiative along the entire line of contact. Under these circumstances, the Kiev regime resorts to terrorist methods, attacking civilian targets and energy infrastructure facilities, to which we are forced to respond accordingly. *** Donald Trump repeatedly emphasised the imperative of establishing peace in Ukraine at the earliest opportunity. The notion that the Russian-Ukrainian conflict has proven the most intractable issue in all peacekeeping efforts of the US President was palpably evident throughout his remarks during the conversation. In this context, he naturally mentioned his successes in settling eight other regional conflicts. It is noteworthy that one of the US President’s key arguments centred on the premise that the resolution of the conflict in Ukraine would open up tremendous — and he stressed this — tremendous prospects for the development of US-Russian economic cooperation. Incidentally, both Sides spoke of the profound mutual affinity between the peoples of the two countries, which was so vividly demonstrated during #WWII. It was underscored that the current state of bilateral relations appears paradoxical against this backdrop. The issue of potential supplies of long-range Tomahawk cruise missiles to Ukraine was also raised. Vladimir Putin reiterated his position that Tomahawks would not change the situation on the battlefield but would inflict substantial damage to relations between our countries, to say nothing of the prospects for a peaceful settlement. In this context, it is worthy of note that the Presidents discussed the possibility of holding another personal meeting. This is indeed a very significant development. It was agreed that representatives of both countries would immediately begin preparations for the Summit, which could potentially be organised in Budapest, for instance. On a separate note, it should be mentioned that our President highly praised personal efforts of the First Lady of the United States Melania Trump in reuniting Russian and Ukrainian children with their families and asked the US President to convey his very best wishes to his spouse. Overall, I would say that the telephone contact between the Presidents of Russia and the United States was quite useful, and the two Leaders agreed to maintain contact. 🇷🇺🇺🇸#RussiaUS