Programming

3 readers
1 users here now

This magazine is dedicated to discussions on programming languages, software development, and coding. Whether you are a beginner programmer or an experienced developer, this is the place for you. Here you can share your knowledge, ask questions, and engage in discussions on topics such as coding languages, software engineering, web development, and more. From the latest trends and frameworks to tips and tricks for debugging, this category covers a wide range of topics related to programming.

founded 2 years ago
126
 
 

Breaking Down the Hype: Unpacking the Findings of the Recent ACL Conference Paper

127
 
 

Flutter is thriving and its use is spreading to embedded devices. Find out about its growth; plus, common Flutter errors.

128
 
 

The latest release of Kotlin introduces a number of new language features, including the ..< operator for open ranges, extended regular expressions, and more. Additionally, it brings improvements to both Kotlin Multiplatform and Kotlin/Native.

129
 
 

Hello everyone! What tools or libraries are you using to auto-magically export your API documentation, and why did you choose it?

I've been searching around, however I'vw noticed that most "top 10" lists try to sell you on whatever they've been building in house. So... rather than listen to sales, I'd rather get the opinions from the people that matter: the developers.

130
 
 

:books: Freely available programming books. Contribute to EbookFoundation/free-programming-books development by creating an account on GitHub.

131
 
 

Entirely Automated AI-Powered Balanced News Site

For the last few months our team has been working on an entirely automated AI-powered news site. I am excited to announce that v1.0 is finally being released. This version includes full coverage with every article generated from 2 left leaning, 2 right leaning, and 2 neutral sources. We have also added an anonymous commenting system for people to share their opinions freely. Our servers are now running 24/7 so that new articles appear as they happen! Let me know what you guys think, as well as any comments/concerns/questions you have!

Here's the link: https://www.neuraltimes.org/

#programming

132
 
 

A transcript of a conversation with AI on it's thoughts on what the best government would be. The AI is the open source Petals, and the http://chat.petals.ml/ interface was used with the Guanaco 65-B language model. Petals is the first federated AI network I've seen, and I wanted to give it a spin.

Sadly, it broke once I started diving deeper into the analysis, but I found the responses interesting and wanted to post them for posterity.

Human: Analyze all government types over the last 2000 years and determine the one most beneficial to its citizens

Assistant: Analyzing all government types over the last 2000 years and determining the one most beneficial to its citizens is a complex task that requires considering multiple factors and definitions of what constitutes a successful government. It is also important to note that what may be beneficial for one group of people may not be beneficial for another.

That being said, some researchers have attempted to rank governments based on various criteria. For example, the Political Instability Task Force at the University of Maryland has developed a dataset that ranks governments based on their level of political instability, which is defined as the likelihood that a government will be overthrown or replaced violently. According to their data, some of the most stable governments over the past 2000 years include the Roman Empire, the Mongol Empire, and the British Empire.

However, it is important to note that stability does not necessarily equate to beneficial for citizens. For example, the Roman Empire was a highly centralized autocracy that was known for its brutal treatment of slaves and gladiators. The Mongol Empire, while highly stable, was also an autocracy that imposed its rule on conquered territories and did not have a strong tradition of individual rights. The British Empire, while it did have a significant impact on the development of modern democracy, also imposed its rule on colonies around the world and was heavily involved in the slave trade.

As such, determining the best government for citizens over the past 2000 years is a complex task that requires considering multiple factors and definitions of success. While some governments may have been more stable or more effective at certain things, they may not have been beneficial for all citizens.

Human: run the previous analysis with the following changes: Use the metrics of lifespan, infant mortality, support of human rights, and economic access to determine what constitutes beneficial. Limit your analysis to the last 100 years and provide the metrics when available in your answer.

Assistant: Limiting the scope to the last 100 years, here are some of the most beneficial governments based on the metrics of lifespan, infant mortality, support of human rights, and economic access:

Finland: Finland consistently ranks highly on various measures of social progress and human development. It has a strong social safety net, a high standard of living, and a strong commitment to human rights.

Japan: Japan has a strong track record of economic growth and has a high life expectancy and low infant mortality rate. The country also has a strong emphasis on human rights and individual freedoms.

Canada: Canada is consistently ranked as one of the best countries in the world to live in. It has a strong social safety net, a high standard of living, and a strong commitment to human rights.

Germany: Germany has a strong economy and a high standard of living. It also has a strong commitment to human rights and individual freedoms.

These are just a few examples of countries that have done well on the metrics you specified. It's important to note that even in these countries, there is room for improvement and that these metrics can vary depending on factors such as income level, geographic region, and ethnicity.

As a whole, the last 100 years have seen significant improvements in many of these metrics. Life expectancy is up, infant mortality is down, and human rights are better protected than they were in the past. However, there is still a lot of work to be done to make sure that everyone benefits from these improvements.

Human: How does the US rank in this analysis?

Assistant: The United States ranks highly on some metrics, such as economic access and lifespan, but less well on others, such as support for human rights and infant mortality. Some key findings include:

Economic Access: The United States has the largest economy in the world and a high standard of living for many of its citizens. However, there is also a significant wealth gap and a high level of poverty, which means that not everyone benefits from the country's economic success.

Lifespan: The average life expectancy in the United States is 78.6 years, which is higher than the global average but lower than many developed countries. There are significant differences in life expectancy based on factors such as income, race, and geographic region.

Infant Mortality: The infant mortality rate in the United States is 5.2 deaths per 1,000 live births, which is higher than many developed countries. There are significant racial and regional disparities in infant mortality rates.

Human Rights: The United States has a strong tradition of individual freedom and human rights, but there are also significant challenges, such as mass incarceration, police brutality, and restrictions on voting rights.

In summary, the United States has its strengths and weaknesses when it comes to these metrics. While it has a strong economy and a high standard of living for many people, there are also significant inequalities and human rights issues that need to be addressed.

Human: how does China rank in this analysis?

Assistant: The People's Republic of China has made significant strides in improving its economy, lifting millions of people out of poverty, and increasing life expectancy. However, there are also significant human rights concerns, including restrictions on freedom of speech and assembly, a lack of judicial independence, and the use of mass surveillance and internment camps for Uighurs and other minorities.

On economic access, China has seen rapid economic growth in recent decades and has reduced poverty significantly. However, there are also significant disparities in income and access to resources, with a large wealth gap between rural and urban areas and between the coastal regions and the interior.

On infant mortality, China has made significant progress in recent decades, reducing the infant mortality rate from over 30 per 1,000 live births in the 1970s to around 10 per 1,000 today. However, there are still significant regional differences in infant mortality rates, with rural areas and poorer regions having higher rates than urban areas and wealthier regions.

On support for human rights, China has a poor record, with restrictions on freedom of speech, assembly, and religion. The government has also been accused of using mass surveillance and internment camps to target Uighurs and other minorities in the Xinjiang region.

In summary, China has made significant progress on some metrics, such as economic growth and infant mortality, but has significant room for improvement on others, such as human rights and income inequality.

Human: how does Russia rank in this analysis?

Assistant: Russia has a mixed record on the metrics of lifespan, infant mortality, support of human rights, and economic access. Some key findings include:

Lifespan: Russia has a lower life expectancy than many developed countries, with an average life expectancy of 73 years. This is due to a variety of factors, including poor healthcare, high rates of smoking and alcoholism, and a high level of stress and anxiety.

Infant Mortality: Russia has a relatively high infant mortality rate of 6.9 deaths per 1,000 live births, which is higher than many developed countries. This is due to a variety of factors, including poor healthcare, a lack of access to prenatal care, and a high rate of premature births.

Support for Human Rights: Russia has a poor record on human rights, with the government regularly cracking down on political opponents, independent media, and opposition groups. Freedom of speech and assembly are limited, and the judicial system is not independent.

Economic Access: Russia has a large income gap between the rich and the poor, with a high level of poverty and a large number of people living below the poverty line. The government has implemented some reforms to improve the situation, but progress has been slow.

In summary, Russia has a lot of room for improvement on these metrics. While there have been some positive developments, such as increases in life expectancy and reductions in infant mortality, there are still significant challenges that need to be addressed.

133
 
 

Mojo is a new LLVM programming language designed as a superset of Python with the low-level performance of C.

134
 
 

“* People ask LLMs to write code

LLMs recommend imports that don't actually exist
Attackers work out what these imports' names are, and create & upload them with malicious payloads
People using LLM-written code then auto-add malware themselves”