D
D
Denis2020-06-30 00:05:22
Python
Denis, 2020-06-30 00:05:22

Why did the file become larger after deleting characters, python?

The crux of the matter is as follows. I have a conditionally 97-byte file, after deleting line breaks and spaces, there remains a direct text that writes to another file. For clarity, again, take a css file.
I turn something like this:

h2 {
    font-size: 16px;
}

span {
    color: red;
}

#pos {
    position: relative;
}

In it:
h2{font-size:16px;}span{color:red;}#pos{position:relative;}h2{font-size:16px;}span{color:red;}#pos{position:relative;}


After the above manipulations, the file began to weigh 118 bytes. The question is why, after removing line breaks and spaces, taking into account empty lines, the file began to weigh more. Google doesn't provide much needed information. Might be a solution for this issue here.

Answer the question

In order to leave comments, you need to log in

1 answer(s)
1
15432, 2020-06-30
@15432

As a result, the same thing is recorded twice, maybe that's why?

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question