magento2 – Magento 2 – How to find out where certain blocks are defined?

I try to remove some blocks on the 404 site:

enter image description here

but I have no idea where they are defined.
I searched in the layout file vendormagentomodule-catalog-searchviewfrontendlayoutcatalogsearch_result_index.xml and searched other catalogsearch_result_index.xml files but I am unable to figure out where these are defined so I can remove them.

formal languages – Is string spliting formally defined when the string delimiter is an empty string?

Depending on the API/language you use, splitting the string "ABCD" using "" as a delimiter gets you:

  • ["A", "B", "C", "D"] in Java, Javascript, and Go
  • ["", "A", "B", "C", "D", ""] in Rust
  • ["ABCD"] in C#
  • Fails with an Exception in Python3

From the perspective of formal language design, what is the correct result of such an operation? Is it defined?

Disclosure: This question was posted at stack overflow but was closed as opinion-based. I was directed to post my question here instead.

8 – Command “generate-votes” is not defined

I’d like to use Drush 10.3.6 to generate votes on my development server.

Based on these instructions for a previous version of drush (8.x) there seems to be some kind of module/extension for this;

drush generate-votes

However when I try this it doesn’t seem to work for me;

root@e63cb10b8a1b:/opt/drupal# drush generate-votes


  Command "generate-votes" is not defined.

Has this feature been removed or deprecated? Is there any other way I can generate votes from the command line?

sharepoint online – jQuery is not defined in SPFx extension

I have created SPFx extension (not a webpart, in case it makes any difference) and trying to add jQuery but its not doing it.
I have installed it into package with
npm install --save @types/jquery
added

"externals": {
      "jquery": "./src/extensions/tracker2/js/JQuery_3.5.1.js"
  },

into config.json ,
import * as jQuery from 'jquery';
into MyPackage.ts
But still getting ” jQuery is not defined ” when trying to use jQuery in my code.

Thanks

Is Rodriguez’s representation of the Laguerre polynomials defined $L_n^k(x)= cfrac{e^xx^{-k}}{n!}cfrac{d^n}{dx^n}(e^{-x}x^{n+k})$?

$L_n^k(x)= cfrac{e^xx^{-k}}{n!}cfrac{d^n}{dx^n}(e^{-x}x^{n+k})$

I saw this in a pdf where $ L_n ^ k (x) $ was taken like this by definition, but, I wonder if it can be deduced that way,
So I tried to deduce it from the equality:

$L_n^k(x)=(-1)^{k}cfrac{d^k}{dx^k}L_{n+k}(x)$

And equality:

$L_n(x)=cfrac{e^x}{n!}cfrac{d^n}{dx^n}(x^ne^{-x})$

So substituting $ n + k $ in $ n $

$L_{n+k}(x)=cfrac{e^x}{(n+k)!}cfrac{d^{n+k}}{dx^{n+k}}(x^{n+k}e^{-x})$

and therefore:

$L_n^k(x)=(-1)^{k}cfrac{d^k}{dx^k}cfrac{e^x}{(n+k)!}cfrac{d^{n+k}}{dx^{n+k}}(x^{n+k}e^{-x})$

But I no longer know how to continue, or is identity taken by definition?

npm – Create local TypeScript package with types and functions defined in separate source files

I am trying to learn npm and TypeScript. My aim is to create a TypeScript package called scrape-jobs in one project and use it in another. I want to keep my type definitions separate from my function definitions (in the source code) if at all possible.

After building my project, my scrape-jobs folder structure is as follows:

|   .eslintignore
|   .eslintrc
|   .prettierrc
|   package-lock.json
|   package.json
|   tsconfig.json
|   
+---build
|       functions.d.ts
|       functions.d.ts.map
|       functions.js
|       functions.js.map
|       types.d.ts
|       types.d.ts.map
|       types.js
|       types.js.map
|       
+---src
|       functions.ts
|       types.ts       

As shown, the declaration files for my functions and types are now in two files: functions.d.ts and types.d.ts. However, the "types" property in package.json only allows for a single value, so how can I specify both *.d.ts files to the consuming project?

installation – Magento 2.4.1 setup:install problem : “the default website isn’t defined. Set the website and try again.”

I finally managed to to work this:

Use composer version 1.9.0:

1. Instal composer 1.9. Or You can downgrade it.

  • cd /var/www/html/mag241/

  • php -r “copy(‘https://getcomposer.org/installer’,
    ‘composer-setup.php’);”

  • sudo php composer-setup.php –install-dir=/bin/composer19
    –version=1.9.0

2. Use composer 1.9 to get magento2.4.1.

- php /bin/composer19/composer.phar create-project

–repository-url=https://repo.magento.com/ magento/project-community-edition=2.4.1 .

3. Run bin/magento setup:install with Your database adres login and url

- php bin/magento setup:install --base-url=http://magento24.local/

–db-host=localhost –db-name=magento24 –db-user=user24 –db-password=1234 –admin-firstname=Magento –admin-lastname=User –admin-email=user@example.com –admin-user=admin –admin-password=admin123 –language=en_US –currency=USD –timezone=America/Chicago –use-rewrites=1 –search-engine=elasticsearch7 –elasticsearch-host=es-host.example.com –elasticsearch-port=9200

object oriented – How can you call a function from within a constructor when the contractor is defined before he function definition?

I have gone through multiple posts but am unable to find an answer to my very basic question on classes and so asking it here, it would be great if someone could shed some light on this topic-

I have a twofold question which is generic to any OOP language-

1]When a class is instantiated what are the exact steps that take place and how is memory allocated to the member functions and the attributes of the class and in what order? As in is memory first allocate to the member functions of the class or the attributes of the class?

2]I understand that it is possible to call functions of a class from within the constructor of the class, but I am unable to understand how this is possible and how the constructor knows of the existence of the function being called as the function being called is defined after the constructor and according to my understanding when instantiating a class the constructor is the first function that is called and executed so this would mean that the other member functions of the class have still not been allocated any memory and do not exist. Is my understanding clear here or am I missing something?

Some help would be highly appreciated.

Integral of a function defined with a loop

I have defined a function g as

g(t_) := (
   res = 0;
   i = 1;
   While(i <= t,
     res = res + i;
     i = i + 1;
   );
   res);

The aim is to work with the function F(u), which should be a the integral of g in bounds $(0,u)$, something like

F(u_) := Integrate(g(y), {y, 0, u})

However, the result I obtain for F is not correct with my current definition of g. In fact, F takes value 0 for any argument u (my guess is that this happens because g(y) is immediately evaluated as 0).

How can F be redefined properly?

discrete mathematics – Two relations defined on same sets be equal?

We say two relations (R1 and R2) are equal if:

$$R_1subset X_{i=1}^n A_i$$
$$R_2subset X_{i=1}^m B_i$$
then,
$$n = m $$
$$A_i=B_iquad forall i,,1le i le n$$

where Ai and Bi are sets.

So, will the below relations be equal?
$$Name = {x,y},,and,,City = {a,b}$$
let, $$R_1={<p,q>|quad p,epsilon,Nameland q,epsilon,City,quad p,,was,,born,,in,,city,,q}$$
$$R_2={<p,q>|quad p,epsilon,Nameland q,epsilon,City,quad p,,lives,,in,,city,,q}$$
suppose we get,
$$R_1={<x,a>,<y,b>}$$
$$R_2={<x,a>,<y,b>}$$
That is, x was born in the same city which he/she lives in.
Can we say,$$R_1=R_2$$