random – when and why is randomness a bad thing in competitive games?

AFAIK is it a consensus within sport that randomness should be reduced? League of Legends has little RNG, Dota has more, but both games use Rng smoothing algorithms (details for Dota, LoL).

The basic principle is that in the case of randomness, the random chance can easily determine the outcome of a game (instead of player skills), which is not acceptable for professional games and tournaments. Quoting the articles I linked above:

In general, randomness is rejected by the competitive game because it can decide on loss and loss without reflecting the actual level of qualification.

In the league, a single action can determine the outcome of a track or even the game. For this reason, randomness in the game is a sensitive issue. While it can be satisfactory to land a big critical hit on your opponent, it can be frustrating or worse to be a victim of a “happy” crit: a random event can cause an experienced player to hit even one less experienced player loses even though the skillful player made a better game. In a casual game, the decision to include randomness can be a breeze if it makes the game more fun. However, the decision to include randomness in esports has the potential to make or break a professional player's career or determine the outcome of a tournament. As a result, many game developers take measures to reduce the impact of randomness in their games.

Seems reasonable, but … I don't understand, there just seem to be too many counterexamples! Pokemon is insanely random, but Pokemon, as far as I know, is played competitively. More traditionally, poker and bridge seem to be one of the most obvious counterexamples. These games seem to show that it's not that pro-play demands little to no randomness?

When and why does it make sense to reduce the randomness of games that should be played competitively?

For the sake of completeness, I have to include two more opinions on the subject that I have heard / read.

First, someone on Discord told me that poker is not really comparable to LoL because it is less popular (I was amazed to learn that LoL tournaments have tens of millions of viewers while poker only has hundreds of thousands) and that poker is a game of chance . This is why randomness works in poker – randomness in games turns it into gambling, which in itself is a problem.

Second, Extra Credits made a video on the subject saying that randomness can work for competitive games (and IIUC implied that the claim that competitive games need to have little to no randomness is wrong), but the tournament format must be adjusted – instead of eliminating them individually, they should do the tournaments in round robin. But doesn't this create new problems because – correct me if I'm wrong – most people, both players and spectators, don't find Round Robin overly boring?

PHP – Is SQL Injection Still a Bad Thing When the User Is Restricted to Non-Harmful Queries?

Suppose I have a very simple PHP application that acts as the front end for an SQL database. The user enters their query in a field and the app displays the query results in a table.

To prevent a user from changing the table, the SQL user has only read-only query permissions. H. When a user tries to enter something like DELETE * FROM persons or DROP TABLE persons You will receive an error message in the text field.

Is it still considered a "bad form" if this web application is susceptible to SQL injection because the user can run his own (read-only) SQL queries against the database when he intends to use the app?

Architecture – is it a good / bad design to make CRUD from SPA like React?

I'm creating a responsive web app with ReactJS as the front end and MongoDB in the back end. I have the following two options and want to know which is preferred for performing CRUD operations.

Approach 1: Since I come from a traditional JVM-based MVC background like JSPs, Spring-Boot and Spring data, a traditional approach to performing user registration like a CRUD operation is as follows:

Enter the image description here
The node instance behaves effectively like a REST endpoint that performs the authentication search, retrieves http requests, and transforms to a MongoDB-specific document and saves the document. I can see that if I follow this approach, I will have to create and deploy a separate NodeJS process and ReactJS instance.

Approach 2:
With SPA like React, we can also carry out the registration-specific validations and data access on the client side. Instead of making the REST calls to node, we can save the Mongo document directly. so the design is like this:
Enter the image description here

If I follow the approach above, I don't have to create and deploy a separate node instance. I am only deploying the React app via webpack.

The only benefit I see with Approach 1 is that I have the flexibility to switch to a separate thick client like Angular or to a native client for IOS or Android. However, switching to a native client can be done with React Native, and all CRUD-related modules can also be used by the React Native apps.

I would have preferred that Approach 1 It offers flexibility, but looks like a YAGNI approach. Therefore, I would like to know which of the patterns is used by the developer community. Is Approach 2 an anti pattern?

Battery – is it a bad idea to keep your phone charging all the time?

The first part of your question can be found under Ideal charge / discharge percentage for maximum battery life. The answers there explain in detail, so yes, that's it true

Second part afterwards how long… depends on how often You charge it incorrectly, your usage (how many charging cycles) etc. and you can't put a number on it. Remember that batteries will lose a significant lifespan even if they are not used due to aging. For more information, see the answer here. Battery capacity wear and its relationship to charging processes

Politics? WordPress management gets angry and tries to make me look bad

For those who wondered what happened after WordPress's apparent attack. Unfortunately, the attacks continued privately and my landlord attacked my health.

Due to serious corruption problems, it was decided to publish a public crime charge.

Dutch: https://www.e-scooter.nl/corruptie/

Regarding the WordPress plugin project.

The project was attacked from several angles. An American partner from Hollywood (former CEO) turned out to be a saboteur who played a billionaire joke about the project. He met with billionaires and asked me and another partner to wait two years with zero results.

The CEO left the company and the plugin was reformatted into Style.Tools (FEO plugin).

Together with the optimization plugin project, a demo site was created: www.e-scooter.co. The demo was a success. The website has received visitors from 228 countries and is visited on average from 174 countries per week.

Despite the ban on WordPress.org, the project was a success.

One of the newest customers of PageSpeed.pro is Vice President at Mastercard. He was satisfied with the new plugin and it delivered results (top positions at Google).

Google recently published a link to Style.Tools in the developer documentation.

It shows that there was nothing wrong with the company or the project.

This forum may have played a key role in the development of things.

I wish you much strength and security in the coming time!

Too many internal links bad?


don't you do it

Advertise here with CPM banner, CPM email, and CPC context links for just about anything. You can target relevant areas of the website and display ads based on the geographic location of the user, if you wish.

Starts at just $ 1 per CPM or $ 0.10 per CPC.

Loops – looping through a DB data structure bad idea twice, how else?

This is probably a more general programming question and something that came to my mind.

I have only 1 year of experience and recently started reading the book "Clean Code" and came across the Big 0 notation.

These two things basically say that you should never go through a loop twice (loop inside the loop) because the performance is awful (O (2n) if I remember correctly).

My question is:

If I have this structure, which is an array of all the orders in my app, and there is an object within that array, that object contains another array that is the single product that was in that order.

  orderOne: {

    products: (
     {name: "Life advice", price: 399},
     {name: "Test", price: 429},

    userInformation: {
    name: "John",
    age: 21

In order to now display all orders in my view, I would first have to go through the total orders and then go through the product array inside within this loop, creating this double loop.

How would this be avoided? It is inevitable that there is an array to store data within an array, which would always mean a double loop.

I try to understand better how to structure things instead of going head first and just writing double loops everywhere.

Thanks for your time!

Stay safe!

Resolution – Why are 48 megapixel pictures taken with a 4k camcorder very bad?

Video cameras can get away with a lot more noise due to the low resolution of video and the noise averaged over time. This camera has a sensor with a crop factor of 7.9, which means that it has 1/64 the area of ​​a full-frame sensor. It would actually be surprising if it even had the advertised 4K on the longer side, but you have an 8K × 6K photo, so even adopt a real 4K sensor (which would be surprising with this sensor size), only 1 in 4 Pixels have the option of not being the result of an interpolation. However, the stair case of oblique lines does not look like interpolation by a factor of 2, but at least by 4, so that only 1 in 16 (or more like 25) pixels is based on actual image data and not on interpolation.

That said, this camera is garbage, not a 4K camera. It can produce output of 4000 pixels per line in video mode, but the actual resolution at which the camera works is much smaller.

The image sensor is probably similar to what was used in functional phones 10 years ago. The EXIF ​​data does not even contain a manufacturer or brand name.

Just write it down. This thing is kidding.

digital – I took pictures with a 4k camera and the picture is very bad

I bought a 4k Ultra HD digital camcorder and took a picture with it. I don't know much about cameras or photography, but I expected the image to be as sharp as high-resolution images.

But when I zoom to 100%, it gets pixelated. It was very uncomfortable, so I quickly checked the properties of the picture, see below.

Enter the image description here

I thought a 4K picture would be much better at 100% zoom than a standard cell phone picture. When I zoom in, it looks like it was taken with a 10 year old cell phone.

What is wrong with what I expect or do? Are there settings for taking a high-resolution image?

I look at the picture with a resolution of 8000 × 6000 on a 17 inch notebook, if that is important.

Photo taken with Samsung A20s phone and lighting

Photo taken with camera and lighting