U
U
user_of_toster2021-12-16 15:12:37
Career in IT
user_of_toster, 2021-12-16 15:12:37

Is there any sense in working with code of not the best quality?

I work on a project with not the best code quality, there are functions for 1-10 thousand lines, most likely no one has heard about the concept of clean code, strong connectivity. Not quite hell, but except for the code authors, most likely no one knows how the other part of the project works.

I turn a blind eye to this only because you need to be able to work with such code.

On the other hand, is it really true? Wouldn't it be better to strive to always work in teams with a greater focus on code quality? Or are these on the market do not survive and you need to get used to this "quality"?

Answer the question

In order to leave comments, you need to log in

3 answer(s)
S
Sergey Gornostaev, 2021-12-16
@user_of_toster

61bb50ed42a6d179971718.jpeg

J
jarvis, 2021-12-24
@jarvis

Yes, if you do a refactoring of all this + describe this experience, then there will be a strong line in the resume. At your next job, you can ask for more)

A
Alexey Ukolov, 2015-07-15
@denis_bardak

This is called a variable with a variable name ( variable variable ).

class Foo {
  public $deepest = 'Limbo';
  
  public function __toString()
  {
    return 'deep';
  }
}

$deeper = 'deepest';
$deep = 'deeper';
$b = new Foo();

echo $b->$$$b;

The expression is evaluated from right to left:
1. $b->$$($b) becomes $b->$$($b->__toString()) because that's how objects behave when they're echoed ;
2. $b->$$($b->__toString()) turns into $b->$(${'deep'}) , this is the value returned by the __toString method of the Foo class whose instance is $b ;
3. $b->$(${'deep'}) turns into $b->$($deep) , this is just calling a variable using the value from another variable;
4. $b->$($deep) becomes $b->${', because that's the value in the $deep variable ;
5. $b->${'deeper'} becomes $b->($deeper) ;
6. $b->($deeper) becomes $b->deepest ;
7. Finally, the value of the 'deepest' property from $b is obtained, and 'Limbo' is stored there , and it is displayed in echo .
dd178a12658f41679b71884846669132.jpg

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question