text:
Generate square sub-matrices of 1's
Back again, stealing another question from stackoverflow.
You are given a list of integers >= 0. Generate in order square 1-matrices where the side length is given by the list entry of the current index and fill the rest with 0s.
So given a list 2,4,1,3 print this to stdout:
1 1 0 0 0 0 0 0 0 0
1 1 0 0 0 0 0 0 0 0
0 0 1 1 1 1 0 0 0 0
0 0 1 1 1 1 0 0 0 0
0 0 1 1 1 1 0 0 0 0
0 0 1 1 1 1 0 0 0 0
0 0 0 0 0 0 1 0 0 0
0 0 0 0 0 0 0 1 1 1
0 0 0 0 0 0 0 1 1 1
0 0 0 0 0 0 0 1 1 1

Rules

Efficiency doesn't matter. (as long as it terminates on e.g. TIO)
Standard loopholes are forbidden.
In/Output has to adhere to the default I/O consensus.
This is code-golf. Shortest answer in bytes wins!

A nice question, but a duplicate.

Sorry, that one wouldn't pop up when I searched for duplicates.


text:
It's as easy as 1,2,3 (except you have to add them up)
Let's consider a list \$L\$ (initially empty) and a pointer \$p\$ into this list (initialized to \$0\$).
Given a pair of integers \$(m,n)\$, with \$m\ge 0\$ and \$n>0\$:

We set all uninitialized values in \$L\$ up to \$p+m+n\$ (excluded) to \$0\$.
We advance the pointer by adding \$m\$ to \$p\$.
We create a vector \$[1,2,...,n]\$ and 'add' it to \$L\$ at the position \$p\$ updated above. More formally: \$L_{p+k} \gets L_{p+k}+k+1\$ for each \$k\$ in \$[0,..,n-1]\$.

We repeat this process with the next pair \$(m,n)\$, if any.
Your task is to take a list of pairs \$(m,n)\$ as input and to print or return the final state of \$L\$.
Example
Input: [[0,3],[1,4],[5,2]]

initialization:
p = 0, L = []

after [0,3]:
p = 0, L = [0,0,0]
         + [1,2,3]
         = [1,2,3]

after [1,4]:
p = 1, L = [1,2,3,0,0]
         +   [1,2,3,4]
         = [1,3,5,3,4]

after [5,2]:
p = 6, L = [1,3,5,3,4,0,0,0]
         +             [1,2]
         = [1,3,5,3,4,0,1,2]

Rules

Instead of a list of pairs, you may take the input as a flat list \$(m_0,n_0,m_1,n_1,...)\$ or as two separated lists \$(m_0,m_1,...)\$ and \$(n_0,n_1,...)\$.
You may assume that the input is non-empty.
The output must not contain any trailing \$0\$'s. However, all intermediate or leading \$0\$'s must be included (if any).
This is code-golf.

Test cases
Input:
[[0,3]]
[[2,3]]
[[0,4],[0,5],[0,6]]
[[0,3],[2,2],[2,1]]
[[0,1],[4,1]]
[[0,3],[1,4],[5,2]]
[[3,4],[3,4],[3,4]]
[[0,1],[1,2],[2,3],[3,4]]
[[2,10],[1,5],[2,8],[4,4],[6,5]]

Output:
[1,2,3]
[0,0,1,2,3]
[3,6,9,12,10,6]
[1,2,4,2,1]
[1,0,0,0,1]
[1,3,5,3,4,0,1,2]
[0,0,0,1,2,3,5,2,3,5,2,3,4]
[1,1,2,1,2,3,1,2,3,4]
[0,0,1,3,5,8,11,14,11,14,17,20,12,0,0,1,2,3,4,5]

@KevinCruijssen Given that I usually try to avoid edge cases and given that another answer is already doing something special with the empty list, supporting it is now optional.

Thanks, that saves me a bit of trouble fixing it, since my program was outputting 0 due to the sum at the end.

Jelly, 12 11 bytes
+ɼ0x;R}ʋ/€S

Try it online!
A full program that takes a list of lists of integers as its argument and returns a list of integers. Can be adapted to work as a link by resetting the register to zero after each call (as implemented in the footer on TIO).
Saved a byte now list can be non-empty.

J, 27 bytes
[:+/[(>:@i.@[,~0$~])"0+/\@]

Try it online!
Takes two separate lists for m an n - the list for n is the left argument of the function, the list for m - the right one.
K (ngn/k), 42 bytes
{+/{x,'((|/#'x)-#'x)#'0}((+\x)#'0),'1+!'y}

Try it online!
Takes two separate lists for m an n
It's too long currently, I'll try to golf it.

I tried solving this independently and came up with something very similar, but 25 bytes.  Kind of fun 3 nested dyadic hooks +/@(((,~#&0)~1+i.)"0~+/\): Try it online!

@Jonah Great! I don't mind if you post it separately.

Java 8, 148 147 bytes
N->M->{int l=M.length,s=M[l-1],p=0,L[],i=0,j;for(int n:N)s+=n;for(L=new int[s];i<l;i++)for(p+=N[i],j=s;j-->0;)L[j]-=j<p|j>=p+M[i]?0:~j+p;return L;}

-1 byte thanks to @ceilingcat.
Takes both integer-arrays as separated inputs.
Try it online.
Explanation:
N->M->{            // Method with integer-array as two parameters as well as return-type
  int l=M.length,  //  Length of the input-arrays
      s=           //  Length of the output-array,
        M[l-1],    //  starting at the last pointer-item of array `M`
      p=0,         //  Position `p` as specified in the challenge, starting at 0
      L[],         //  Output list, starting uninitialized
      i=0,j;       //  Index integers
  for(int n:N)     //  Loop over the value-list `N`:
    s+=n;          //   And add all of them to the output-length
  for(L=new int[s];//  Now initialize the output-list of size `s`, filled with 0s by default
      i<l;i++)     //  Loop `i` in the range [0, `l`):
    for(p+=N[i],   //   Increase position `p` by the `i`'th pointer of `N`
        j=s;j-->0;)//   Inner loop `j` in the range (`s`,0]:
     L[j]-=        //    Decrease the `j`'th item of the output-list by:
       j<p         //     If `j` is smaller than position `p`
       |j>=        //     or `j` is larger than or equal to
        p+M[i]?    //     pointer `p` and the `i`'th value of `M` combined
         0         //      Leave the `j`'th item of output-array the same by adding 0
       :           //     Else:
        ~j+p;      //      Decrease the `j`'th item of the output-array by `-j-1+p`
                   //      (increase it by the difference between `j` and `p`, plus 1)
  return L;}       //  And after the nested loops: return the resulting array

Jelly,  10  9 bytes
Ä0ẋżR}F€S

A dyadic Link accepting a list of integers on each side, \$M\$ on the left \$N\$ on  the right, which yields a list of integers.
Try it online! Or see the test-suite.
How?
Ä0ẋżR}F€S - Link: list of integers, M; list of integers, N
Ä         - cumulative sums (M) = [m1, m1+m2, m1+m2+m3, ...]
 0ẋ       - zero repeated = [[0]*m1,[0]*(m1+m2),[0]*(m1+m2+m3), ...]
    R}    - range (right=N) = [[[1,2,3,...,n1]],[[1,2,3,...n2]],[[1,2,3,...,n3]], ...]
   ż      - zip together = [[[0]*m1,[[1,2,3,...,n1]]],[[0]*(m1+m2),[[1,2,3,...,n2]]],[[0]*(m1+m2+m3),[[1,2,3,...,n3]]], ...]
      F€  - flatten each = [[0,0,...,0,1,2,3,...,n1],[0,0,...,0,1,2,3,...,n2],[0,0,...,0,1,2,3,...,n3], ...]
        S - sum

Nice. I’d missed the fact that two lists were acceptable input.

Haskell, 90 87 bytes
(foldl(%)[].).zipWith(\o p->(0<$[1..o])++[1..p]).scanl1(+)
(a:b)%(c:d)=a+c:b%d
b%d=b++d

Takes the input as two separate lists [m0,m1,...] and [n0,n1,...].
Try it online!
A variant (function % same as above), also 87 bytes:
(foldl(\l(o,p)->((0<$[1..o])++[1..p])%l)[].).zip.scanl1(+)

Zsh, 59 56 54 bytes
-3 bytes by changing to my Bash strategy, -2 bytes by switching back to my original strategy, now that the rules specify the list is non-empty.
for m n;for ((i=0,p+=m;i<n;a[p+i]+=++i)):
<<<${a/#%/0}

Try it online: [Original strat handling empty case]
[Adapted Bash strat]
[Current]

Setting a[5]=1 causes a[1] through a[4] to be initialized empty. The final parameter expansion replaces all empty elements with 0.
for m n                                 # implicit 'in "$@"'
    for ((i=0, p+=m; i<n; a[p+i]+=++i)) # increment p by m, add to a[p,p+n-1]
        :                               # ':' is a no-op builtin
<<<${a/#%/0}                            # the glob #% matches empty elements

Python 3, 144 119 118 111 110 106 bytes
def f(m,n):
 p=k=0;l=[]
 for i,j in zip(n,m):p+=j;l+=[0]*(p+i-len(l));exec("l[~k]+=i-k;k+=1;"*i)
 return l

Try it online!
Thanks to:
-@mypetlion for saving me 25 bytes

Wolfram Language (Mathematica), 62...50 45 bytes
Plus@@PadRight[a=1;Ramp@Range[a-=#,#2]&@@@#]&

Try it online!
Input a list of pairs.

PHP, 93 bytes
for(;$n=$argv[++$i+1];)for($p+=$argv[$i++];$$i<$p+$n;)$l[$$i]+=$$i++<$p?0:$$i-$p;print_r($l);

Try it online!
Input is a flat list of m0,n0,m1,n1,... passed by command arguments ($argv) and output is string representation of L.

APL (Dyalog Unicode), 19 bytes
1⊥0⌈(↑(⍳+)¨-⊢)∘(+\)

Try it online!
Uses the algorithm described in my J answer.
How it works
1⊥0⌈(↑(⍳+)¨-⊢)∘(+\)  left = n's, right = m's
              ∘(+\)  m2 = cumulative sum of m's
      (⍳+)¨          Nested array of 1..(each element of n+m2)
           -⊢        Subtract each elem of m2 from each row
    (↑       )       Promote nested array to matrix
  0⌈                 Take max with 0 (change negatives to 0)
1⊥                   Sum in column direction

APL (Dyalog Unicode), 20 bytes
{1⊥↑⍺{(⍵⍴0),⍳⍺}¨+\⍵}

Try it online!
A dyadic dfn whose left argument is the ns and right argument is ms.
How it works
{1⊥↑⍺{(⍵⍴0),⍳⍺}¨+\⍵}
{                  }  ⍺ = n's, ⍵ = m's
                +\⍵   Cumulative sum of offsets (M)
    ⍺{        }¨      Zip with n's
      (⍵⍴0),⍳⍺        ... to create M zeros followed by 1..n
   ↑                  Promote to matrix, filling zeros where necessary
 1⊥                   Sum column-wise

Hey Bubbler can you improve this J solution +/@(((,~#&0)~1+i.)"0~+/\)? Try it online!

@Jonah I couldn't shorten that one specifically, but I could come up with a shorter solution using a different approach.

full program: 1⊥0⌈↑a-⍨⍳¨⎕+a←+\⎕

1⊥↑⎕{+\⍸⍵⍺}¨+\⎕ in some future version of dyalog, with ⎕io←0

05AB1E, 13 bytes
ηOÅ0s€L‚ø€˜0ζO

Takes two separated lists. The list of positions \$(m_0, m_1, m_2, ...)\$ as first input and list of values \$(n_0, n_1, n_2, ...)\$ as second input.
Try it online or verify all test cases.
Explanation:
η        # Get all prefixes of the (implicit) input-list of positions
         #  i.e. [0,1,5] → [[0],[0,1],[0,1,5]]
 O       # Sum each inner list
         #  → [0,1,6]
  Å0     # Convert each of the inner values into a list of 0s of that length
         #  → [[],[0],[0,0,0,0,0,0]]
s        # Get the second (implicit) input-list of values
 L       # And create a list in the range [1,n] of each value
         #  i.e. [3,4,2] → [[1,2,3],[1,2,3,4],[1,2]]
‚        # Pair the two lists together
         #  → [[[],[0],[0,0,0,0,0,0]],[[1,2,3],[1,2,3,4],[1,2]]]
 ø       # Zip/transpose, swapping rows/columns
         #  → [[[],[1,2,3]],[[0],[1,2,3,4]],[[0,0,0,0,0,0],[1,2]]]
  €˜     # Flatten each inner pair to a single inner list
         #  → [[1,2,3],[0,1,2,3,4],[0,0,0,0,0,0,1,2]]
    0ζ   # Zip/transpose, swapping rows/column, with 0 as trailing filler
         #  → [[1,0,0],[2,1,0],[3,2,0],[0,3,0],[0,4,0],[0,0,0],[0,0,1],[0,0,2]]
      O  # Take the sum of each inner list
         #  → [1,3,5,3,4,0,1,2]
         # (after which the result is output implicitly)

Ruby, 92 88 84 bytes
->x{n,l=0,[];x.map{|a,b|0.upto(b-1+n+=a){|i|l[i]||=0};1.upto(b){|i|l[-i]+=1+b-i}};l}

Input is a list of pairs, in the form [[m1, n1], [m2, m2], ...].
The approach is pretty much the algorithm as described.
Golfy tricks I've used include:

l[i]||=0 setting the value for L to 0 if it isn't already set
That's pretty much it.

Thanks to Value Ink for
Try it online!
Ruby can be pretty terse. When the version with numbered block parameters comes out, this can be reduced by a few bytes to this (note the @1 ins:
->x{n,l=0,[];x.map{|a,b|0.upto(b-1+n+=a){l[@1]||=0};1.upto(b){l[-@1]+=1+b-@1}};l}

Why are you ending your map block with returning l and then taking [-1], when you can just do ;l after the map? Like so.

Two more things I thought up: n,*l=0 will initiate l to the empty array for -2 bytes, and you can wrap the n+=a into your upto call like so: 0.upto(b-1+n+=a)

J, 20 bytes
+/@(0>.>:@i.@+-])+/\

Try it online!
I guess this is quite different from both Galen Ivanov's and Jonah's answers. A dyadic train that takes ns as left argument and ms as right.
One trick was to avoid (...)"0 (apply to each item) in favor of ...@+. The conjunction u@v has the effect of u@:v"v. The rank-forcing effect is usually not desirable when v is an arithmetic verb, but it works perfectly here.
How it works
+/@(0>.>:@i.@+-])+/\  Left(n): range generators ex) 3 4 2
                      Right(m): offsets ex) 0 1 5
                 +/\  cm: Cumulative sum of offsets ex) 0 1 6
             +        Add n and cm element-wise ex) 3 5 8
          i.@         Generate 0..x-1 for each x above
                      ex) 0 1 2;0 1 2 3 4;0 1 2 3 4 5 6 7
       >:@            Increment each value
                      ex) 1 2 3;1 2 3 4 5;1 2 3 4 5 6 7 8
                      (Implicit) Form a 2D array, padding with 0s where needed
              -]      Subtract each item of cm from each row of above
                      ex)  1  2  3  0  0  0  0  0
                           0  1  2  3  4 -1 -1 -1
                          -5 -4 -3 -2 -1  0  1  2
    0>.               Max with 0; Change negative numbers to 0s
+/@(            )     Take sum in column direction

very nice @Bubbler

Bash, 77 bytes
for N;{
b=($N)
for((i=0,p+=b;i<p+b[1];a[i]+=++i>p?i-p:0)){ :;}
}
echo ${a[@]}

Try it online!
I couldn't port my first Zsh answer directly, since ${a[@]/#%/0} doesn't work in Bash. So instead of fixing the empty elements at the end, I set all the elements with a[i]+=0 along the way. In the end, this strategy works out better for Zsh anyway!

K (ngn/k), 30 bytes
{+/0^(1+!'y)@'-n-\:!*|y+n:+\x}

Try it online!

i tried to beat this with "amend" but i couldn't. my best is: {@[&0|/y+j;i+j:+\x;+;1+i:!'y]}

C, 204 196 195 192 185 bytes
*c(m,n,q,x,p,z)int*m,*n;{int i,j,*a=malloc(4);for(i=p=z=0;m[i]+1;i++){q=n[i]+(p+=m[i]);a=realloc(a,8*((x=z)>q?z:(z=q)));bzero(a+x,(z-x)*8);for(j=p;j<q;j++)a[j]+=j-p+1;}a[z]--;return a;}

De-golfed version:
* count (m, n, size_of_array, pointer_into_array, previous_size_of_array, final_element_counted_to) //all but m and n are implicitly int - return type of function is implicitly int pointer
     int* m, * n;
{
  pointer_into_array = size_of_array = 0;
  int* array = malloc(sizeof(int)); //get a pointer so we can realloc later
  for (int i = 0; m[i] + 1; i++) { //iterate through m and n, stopping at -1 sentinel value
    final_element_counted_to = n[i] + (pointer_into_array += m[i]); //update pointer, get final element counted to on this pair
    array = realloc(array, sizeof(int) * 2 * ((previous_size_of_array = size_of_array) > final_element_counted_to ? size_of_array : (size_of_array = final_element_counted_to) + 1)); //reallocate array to size of max(size_of_array, final_element_counted_to+1) * sizeof(int) * 2 [multiplying by 2 for the final statement of a[z] = -1]
    bzero(array + previous_size_of_array, (size_of_array - previous_size_of_array) * sizeof(int) * 2); //initialises new memory to zero
    for(int j = pointer_into_array; j < final_element_counted_to; j++) //do the actual counting + adding
      array[j] += j - pointer_into_array + 1;
  }
  array[size_of_array]--; //make sure it's terminated by -1
  return array;
}

Try it online!
Function c takes two arguments (rest are for free declaration) m and n, both -1 terminated arrays corresponding respectively to the two separate lists for m and n. It returns a -1 terminated array.
Please note that this requires sizeof(int) to be 4, and also requires the non-standard and deprecated but widely-implemented function bzero.

Welcome to Code Golf! You can use the header and footer sections of TIO to store boilerplate code: like this. They do not count towards your byte score.

And it seems like you current score is actually 204.

171 bytes

Java, 642 Bytes
This I think is kind of awful, but doing it with Java who knows what I was expecting. If someone could help me make this better I would really appreciate that, a bunch of bytes are taken up dealing with the fact that combiner can get two different length lists and need to add them, and also with the fact that there is a type needed for the BiConsumer lambda. I think there are a few ways, but it's getting late...
Input is n, expected to be an array of arrays.
    IntStream.range(0, n.length).mapToObj((x) -> new int[] { n[x][0] + (x > 0 ? n[x - 1][0] : 0), n[x][1]})
            .map((v) -> IntStream.range(0, v[0] + v[1]).map((x) -> x >= v[0] ? 1 + x - v[0] : 0).toArray())
            .collect(Collector.of(
                () -> new ArrayList<>(),
                (BiConsumer<List<Integer>, int[]>) (l, v) -> IntStream.range(0, Math.max(l.size(), v.length)).forEach((i) -> {
                    if (i >= l.size()) l.add(0);
                    if (i < v.length) l.set(i, l.get(i) + v[i]);
                }),
                (a, b) -> {
                    while (a.size() > b.size()) b.add(0);
                    while (b.size() > a.size()) a.add(0);
                    return IntStream.range(0, a.size()).mapToObj((i) -> a.get(i) + b.get(i)).collect(Collectors.toList());
                },
                Characteristics.IDENTITY_FINISH
            ));

Improved and golf'd by Kevin Cruijssen:
n->IntStream.range(0,n.length).mapToObj(x->new int[]{n[x][0]+(x>0?n[x-1][0]:0),n[x][1]}).map(v->IntStream.range(0,v[0]+v[1]).map(x->x<v[0]?0:1+x-v[0]).toArray()).collect(Collector.of(()->new Stack<>(),(java.util.function.BiConsumer<List<Integer>,int[]>)(l,v)->IntStream.range(0,Math.max(l.size(),v.length)).forEach(i->{if(i>=l.size())l.add(0);if(i<v.length)l.set(i,l.get(i)+v[i]);}),(a,b)->{while(a.size()>b.size())b.add(0);while(b.size()>a.size())a.add(0);return IntStream.range(0,a.size()).mapToObj(i->a.get(i)+b.get(i)).collect(Collectors.toList());},Collector.Characteristics.IDENTITY_FINISH))

How does this receive input? And surely you can golf away pretty much all the whitespace at least

I'm not sure how you ended up with 581 bytes, because your current code above is 842 bytes and still missing required imports and n-> as input. Removing all whitespaces; parenthesis around the (L)-> everywhere; changing ArrayList to Stack; reversing some checks so we could use a<b?0:1 instead of a>=b?1:0; and some other basic golfs, I end up at 642 bytes. I'm sure this can be a lot shorter without the stream builtins, though.

Anyway, welcome to CGCC! If you haven't seen them yet tips for golfing in Java and tips for golfing in  might both be interesting to read through. Enjoy your stay! :)

To get 581 bytes I minified with https://codebeautify.org/javaviewer and pasted into https://mothereff.in/byte-counter . Should I be pasting the minified version into the code area when posting here?

I realize now that I excluded (n) -> though

Clojure, 170 Bytes
(fn [a](reduce #(mapv +(concat %1(repeat 0))%2)(mapv (fn [[x y]](concat(repeat x 0)(range 1(+ 1 y))))(reduce #(conj %1(mapv +[(nth(last %1)0)0]%2))[(first a)](rest a)))))

Try it online!

Hello and welcome to PPCG!

source: Stack Exchange

license: Creative Commons - Attribution Share-Alike - https://creativecommons.org/licenses/by-sa/4.0/

sort: votes


text:
Ethan Finds the Maximum Element
This is a problem that the Hacker Cup team made for the 2018 Facebook Hacker Cup, but we ended up not using it (though Ethan struggles through a variety of other challenges). Normally code size isn't a factor in the Hacker Cup, but we thought this would make for an interesting code golf challenge. We look forward to seeing how a different sort of competitive programmer tackles this problem!

Ethan has been given quite the challenging programming assignment in school: given a list of \$N\ (1 \le N \le 50)\$ distinct integers \$A_{1..N}\ (1 \le A_i \le 100)\$, he must find the largest one!
Ethan has implemented an algorithm to solve this problem, described by the following pseudocode:

Set \$m\$ to be equal to \$A_1\$.
Iterate \$i\$ upwards from 2 to \$N\$ (inclusive), and for each \$i\$, if \$A_i > A_{i-1}\$, set \$m\$ to be equal to \$A_i\$.
Output \$m\$.

Sometimes this algorithm will output the correct maximum value, but other times it sadly won't.
As Ethan's teaching assistant, you have some say in what input data his solution will be evaluated on. The professor has given you a list of \$N\$ distinct integers \$A_{1..N}\$ to work with, but you may shuffle them into any permutation you'd like before feeding them into Ethan's program. This is your opportunity to show some mercy!
For how many different permutations of \$A_{1..N}\$ would Ethan's algorithm produce the correct output?
Input Format:
Line 1: 1 integer, \$N\$
Line 2: \$N\$ space-separated integers, \$A_{1..N}\$
Output Format:
1 integer, the number of permutations of \$A\$ for which Ethan's algorithm would produce the correct output.
Sample Input 1:
1
100

Sample Output 1:
1

Explanation:
Only one permutation of \$[100]\$ exists, and Ethan's program would correctly output 100 for it.
Sample Input 2:
3
16 82 43

Sample Output 2:
5

Explanation:
Ethan's program would correctly output 82 for 5 of the 6 possible permutations of \$[16, 82, 43]\$. However, when \$A = [82, 16, 43]\$, it would incorrectly output 43 instead.
Sample Input 3:
10
26 81 40 5 65 19 87 27 54 15

Sample Output 3:
986410

Rules
This is code-golf, so shortest answer (in bytes) wins!

Welcome to codegolf :) This is a well specified question but there are a few parts that mismatch the cultures of competitive programming. Particularly the section you labeled "input format" - generally golfing IO is uninteresting and so challenges here usually allow input in any convenient manner. We have a sandbox where you can post challenges for review before they go live. Good luck!

For example, in the sandbox I would have asked why $ A_{n} $ needs to be specified. Since the integers are distinct, only $ N $ matters.

While the %107 spec (and similar avoidances of overly large numbers) is typical on many other competitive programming sites, it's not really part of the culture here. Posters on this forum don't usually care whether an answer is too large to be reasonably displayed.

Thanks for the tips! I'm definitely down to edit this so that we remove the %107 and the first number from the input, though people have already added solutions, so I'm not sure what the etiquette is around that.

The input you can definitely change without particularly impacting answers. The output may be more of a problem, and you could consider asking the people who answered about if they mind the change. Looking at them, most of them would simply remove a literal %107 from their code, so I would suspect that changing it is fine. If you do, make sure you leave a comment on each answer that hasn't updated it so they know to make the change.

Why are we supposed to be corrupt TAs who help students who failed to do their work get good grades?

Please consider using the Sandbox in the future to get feedback on your challenges before posting them to the main site.

Thanks for posting this here! I have two comments. First, thanks for mentioning the problem source at the very start. When I read challenges here that sound like they are from programming contests, I start worrying that they are attempts at cheating or plagiarism. Second, I think less puzzley programming-contest style challenges that are about implementing code work better here. Please do post more if you have them. While this challenge still has room for golfing once you solve out the math "trick", our answers being open means that once someone solves the math, everyone just copies the idea.

APL (Dyalog Unicode), 5 3 bytes
⍳⊥×

Try it online!
Adám gave me an inspiration to golf this further.
How it works
⍳⊥×  Monadic train. Input: n, the length of array A.
  ×  v: Signum, which always gives 1 because n ≥ 1
⍳    B: An array of 0..n-1
 ⊥   Scalar-expand v to get V, a length-n vector of ones,
       then mixed base conversion of V in base B

APL (Dyalog Unicode), 5 bytes
⍳⊥⍴∘1

Try it online!
Edited to remove modulo 107
Uses HyperNeutrino's formula, but optimized through the use of ⊥ (mixed base conversion) directly. Uses ⎕IO←0.
How the code works
⍳⊥⍴∘1  Monadic train. Input: n, the length of array A.
  ⍴∘1  V: An array of 1's of length n
⍳      B: An array of 0..n-1
 ⊥     Mixed base conversion of V in base B

How the ⊥ works
base:  0         1         2         .. n-3         n-2 n-1
digit: 1         1         1         .. 1           1   1
value: 1×..(n-1) 2×..(n-1) 3×..(n-1) .. (n-2)×(n-1) n-1 1
sum of all digit values is the answer.

This is now my all time favorite use of mixed base.

I've edited the problem to remove the mod 107

@Adám Uptack does scalar expansion too?!

-2 bytes: ⍳⊥× Try it online!

@Adám I noticed that too, after seeing your 4-byte comment :)

Jelly, 6 bytes
RU×\S:

Try it online!
Let's analyze under which scenarios this algorithm works.
If the maximum element is at the end of the list, this obviously works, since \$A_N>A_{N-1}\$ and it is processed last. This gives \$(N-1)!\$ possibilities.
If the maximum element is at the second last position, then this obviously works, since \$A_N<A_{N-1}\$ so it is not processed, and \$A_{N-1}>A_{N-2}\$ and is processed last. This gives \$(N-1)!\$ possibilities. There is no overlap between this case and the above because the numbers are guaranteed unique.
If the maximum element is at the third last position, then it depends on the last two elements. If the last element is larger than the second last element, it is treated as the maximum, which fails. There are \$(N-1)!\$ cases, and we can match them by identical first \$(N-3)\$ elements with one case going \$\cdots,max,A,B\$ and the other going \$\cdots,max,B,A\$. Exactly one of these is valid and not the other, so there are \$\frac{(N-1)!}{2}\$ cases.
In general, if the maximum element has \$k\$ elements after it, then the rest of the list must be strictly descending. There is exactly one case for each set of last \$k\$ elements out of the \$k!\$ permutations.
Thus, the answer is \$\frac{(N-1)!}{0!}+\frac{(N-1)!}{1!}+\cdots+\frac{(N-1)!}{(N-1)!}\$. This is OEIS A000522.
This is equal to \$\frac{\frac{N!}{0!}+\frac{N!}{1!}+\cdots+\frac{N!}{(N-1)!}}{N}\$, which is \$\frac{(N\times(N-1)\times(N-2)\times\cdots\times 1+N\times(N-1)\times(N-2)\times\cdots\times 2+\cdots+N}{N}\$, which is the sum of the cumulative product of the list \$[N,N-1,\cdots,2,1]\$, divided by N.
RU×\S:
R       [1, 2, ..., N]
 U      reversed
   \    cumulative
  ×     product
    S   sum
     :  divided by (N)

Having MathJax is really nice :D
Note that the list literally does not matter. All we need to know is N.

I don't think this is right. For [1,2,3,4,5,6] your answer returns 5, but even by hand, I can find more than 5 permutations where Ethan's algorithm will work. 654321,564321,465321,365421,265431,165432,...

@mypetlion mod 107

Yikes! Ignore me, I'm an idiot.

@mypetlion :P it's kinda weird I don't really like it lol...

It's pretty common on other competitive programming sites, but I think mostly out of necessity because answers get judged automatically. OP is new here, so may not be aware that that sort of thing isn't really done. I've left a comment for them.

@mypetlion Whoops, I forgot to do that myself. And yeah, most competitions I do (like actual CP) have mod 1e9+7 but here we usually just accept that once numbers get too large the code won't work but the concept would theoretically be correct lol

Golfing something that actually works for reasonable input values, not just in concept, is also interesting.

@user2357112 That's fair. In this specific case this works for reasonable input values until the output grows too large and that's not a matter of golfed or not, but in general, you have a point.

Since you are only taking one input anyway, you can save a byte by taking only N and changing J to R and dropping the L.

@FryAmTheEggman Oh, I didn't know they changed the format. Thanks!

I've edited the problem to remove the mod 107

To be cheeky, you could take the second input via STDIN :P I don't believe it would affect the program in any way and would still be "taking" a second input

@WesleyMay Okay, thanks!

@cairdcoinheringaahing I mean, I suppose :P

I was about to ask whether the list would matter if there were duplicates, but then I checked the question again.  Distinct integers.  So yes, it would have mattered (e.g. the algorithm always works if all numbers are identical) and that's why they ruled it out.  Also because of ambiguity over what a permutation is when there are duplicates, whether different shuffles producing the same result both count.

Retina, 44 bytes
K`;
"$+"+`(.*);(.*)
$.(_$1*);$.(_$1*$2*
.*;

Try it online! Explanation:
K`;

Replace N with a counter and output (these should be decimal 0, but the empty string works here).
"$+"+`

Repeat N times...
(.*);(.*)
$.(_$1*);$.(_$1*$2*

... multiply the output by the counter and increment both.
.*;

Delete the loop counter.
Previous 47 bytes including modulo 107:
K`;
"$+"{`(i*);(j*)
i$1;j$.1*$2
)`(\w{107})*

j

Try it online! Explanation:
K`;

Replace N with a counter and output (both initially 0).
"$+"{`
)`

Repeat N times...
(i*);(j*)
i$1;j$.1*$2

... multiply the output by the counter and increment both...
(\w{107})*

... and reduce modulo 107.
j

Convert the output to decimal.

I've edited the problem to remove the mod 107

JavaScript (ES6),  19  18 bytes
A shorter version suggested by @Neil
Saved 1 byte thanks to @Jitse
f=n=>n&&--n*f(n)+1

Try it online!
Implements the following formula from A000522:
$$\cases{a_0=1\\
a_{n}=n\cdot a_{n-1} + 1,&n>0}$$
Turned into:
$$\cases{a_0=0\\
a_{n}=(n-1)\cdot a_{n-1} + 1,&n>0}$$

JavaScript (ES6), 35 bytes
This is a port of @HyperNeutrino's answer.
Takes only \$n\$ as input, as per this consensus.
n=>(g=n=>n&&(p*=n)+g(n-1))(n,p=1)/n

Try it online!

The OEIS gives a formula that's only 24 bytes: Try it online!

I've edited the problem to remove the mod 107

@WesleyMay Thanks for the heads up. Updated.

18 bytes

05AB1E, 8 5 4 bytes
-1 byte thanks to @KevinCruijssen
Implementation of @Neil's algorithm.
GNP>

Explanation:
G    for loop from 1 to input
 N   push current iteration
  P  multiply the stack; in the first iteration there's only 1 element (1)
   > increment

Try it online!

I've edited the problem to remove the mod 107

In your current approach the P (product of stack) could be * (multiply). However, your P did give me the idea for -1 byte: simply remove the $. The first iteration will take the product of just the [N=0] on the stack, and every next iteration will take the product of [previousValue,N]: Try it online.

APL (Dyalog Unicode), 12 bytes
×\∘⌽∘⍳∘≢+.÷≢

Try it online!
-4 bytes thanks to the change in specifications;
-3 bytes thanks to @Adám
Train that implements @HyperNeutrino's formula, so go upvote their answer.

I've edited the problem to remove the mod 107

107|×\∘⌽∘⍳∘≢+.÷≢ but you can remove the 107| now.

C (gcc), 69 62 60 bytes
Following the consensus in C;
Updated to the most golfed solution thanks to contributions from Arnauld and FryAmTheEggman.
mod 107 has been removed from the rules, I was being too tricky.  Thanks for the edit Arnauld.
c,o,d,e;f(n){for(e=n;n--;c+=o)for(d=e,o=1;d>n;)o*=d--;c/=e;}

Try it online!

Nice variable naming. ;-)

@Arnauld In fact, you can save another with more fors!

@FryAmTheEggman Going a step further, that can now be written in 62 bytes.

I've edited the problem to remove the mod 107

I didn't notice that you were taking twice the same input, which is not the same as ignoring one of the inputs described in the challenge. I don't think that's allowed. So, I would suggest this 60-byte version instead (without the mod 107).

Mmm yea I was trying to be too tricky.  Something like strcpy(in1,fgets(in2, 100, pFile)); would take the input twice on a single read/line.  But at the time I was just trying to be too tricky and the edit is fair.  Thanks again.

Japt -x, 6 bytes
ÆÉ /Xl

Try it

I've edited the problem to remove the mod 107

107 can be #k

R, 28 bytes
n=scan();sum(cumprod(n:1))/n

Try it online!
R port of @HyperNeutrino’s algorithm.

Python 3, 28 bytes
f=lambda n:n and~-n*f(n-1)+1

Try it online!
Python port of Neil's algorithm.

Ruby, 24 bytes
f=->n{n<1?1:f[n-=1]*n+1}

Try it online!
Using the formula from OEIS A000522

all_licenses: Creative Commons - Attribution Share-Alike - https://creativecommons.org/licenses/by-sa/4.0/


text:
Spelling on a Grid
(based on this deleted question)
Take the English alphabet a b c d e f g h i j k l m n o p q r s t u v w x y z (spaces added for clarity), and split it into chunks of X width, padding any leftover lines with spaces if necessary for your language. For example, splitting it into width 4 results in
a b c d
e f g h
i j k l
m n o p
q r s t
u v w x
y z

Now, given a word composed of [a-z]+, output the path taken to spell that word when starting from a and using ! to specify selecting that letter, with D U R L for Down, Up, Right, Left, respectively.
For the above X=4 example, and the word dog, the output would be R R R ! L D D D ! U U ! (spaces added for clarity and not required in output).
If X=3, you get a different picture of the alphabet:
a b c
d e f
g h i
j k l
m n o
p q r
s t u
v w x
y z

And a different solution for the word dog -- D ! D D D R R ! L L U U !.
Examples
"dog" 4 --> R R R ! L D D D ! U U !
"dog" 3 --> D ! D D D R R ! L L U U !
"hello" 6 --> R D ! R R R U ! R D ! ! D L L L !
"codegolf" 10 --> R R ! R R D ! L U ! R ! R R ! L L D ! L L L ! U R R R R !
"acegikmoqsuwy" 2 --> ! D ! D ! D ! D ! D ! D ! D ! D ! D ! D ! D ! D !

Rules

Note that the grid doesn't wrap, so to get from the leftmost column to the rightmost column requires traversing the entire X distance.
The output must be a shortest possible path, but doesn't necessarily need to be in a particular order. For example, for the first dog example you could instead produce R R R ! D D D L ! U U !, swapping the order of the Downs and the Left, because that's the same length path and achieves the same character.
Similarly, please output only one path (because there will likely be multiple), but that doesn't need to be deterministic (i.e., multiple runs of your program may produce different paths, provided they're all the shortest).
The output doesn't have to have delimiters (like I do here with spaces), that's up to your aesthetic choice.
You can choose input as all-lowercase or all-uppercase, but it must be consistent.
The input number is guaranteed to be in the range 1 to 26 (i.e., a single column to a single row of letters).
Input words are guaranteed to be at least one character long, and match [a-z]+ with no other punctuation, spaces, etc., (i.e., you'll never receive empty string "" as input), but it may not be an actual English word.
Instead of D U R L !, you can choose five characters/numbers/arrows/etc. to represent the direction and selection. For example, you could choose 1 2 3 4 x. This output choice must be consistent across all runs of your code, and please specify in your submission what the output is.
Input and output can be given by any convenient method.
You can print it to STDOUT or return it as a function result.
Either a full program or a function are acceptable.
Standard loopholes are forbidden.
This is code-golf so all usual golfing rules apply, and the shortest code (in bytes) wins.

Can we take the input as a list of integers from 0 to 25 rather than lowercase letters? My Jelly answer spends 4 bytes converting the letters into integers, and in general IO is less interesting for codegolf.

@NickKennedy No, that would radically change the input from "a string and a width."

not really. A list of integers from 0 to 25 where there is a one-to-one correspondence to the letters A to Z and a width as the second input isn’t really any different. I.e. rather than "codegolf" and 10, you would have [2,14,3,4,6,14,11,5] and 10. Anyway, it’s your challenge, so happy to go with whatever you prefer; my current answer takes a word of lower case letters as its first argument as per the spec.

Is there a unique output for the inputs "zy" and 5?

@Neil Not necessarily, because you can optionally pad the z line with spaces.

Well, it turns out that padding doesn't help me, but I saved 4 bytes anyway just trying to get some benefit from it.

K (ngn/k), 41 32 bytes
{,/(|4,&0|,/-:\)'-':+(0,y)\x-97}

Try it online!
output: 0=D 1=R 2=U 3=L 4=!
{ } function with arguments x and y
x-97 convert "a".."z" to 0..25
(0,y)\ divmod by y, returns a pair of lists - one with the quotients and one with the remainders
+ flip - make it a list of pairs
-': deltas - subtract each pair from the previous one; use 0 0 as an implicit pair before the first
( )' for each pair (let's call it (Δi;Δj)) do:

-:\ self and own negation: (Δi;Δj) -> ((Δi;Δj);(-Δi;-Δj))
,/ concatenate: -> (Δi;Δj;-Δi;-Δj)
0| max with 0
& "where" - for instance it would turn the list a:1 5 0 2 into 0 1 1 1 1 1 3 3, i.e. each index i is repeated a[i] times
4, prepend a 4
| reverse

,/ concatenate

that cat with the negative trick is quite nice.  quite nice indeed.

JavaScript (Node.js),  112 ... 104  102 bytes
Takes input as (width)(word), where word is expected in lowercase. Returns 01234 for RLDU!.
n=>w=>Buffer(w).map(g=c=>v-(c%=97)?g(c,v-=[-1,1,-n,n][d=(v-c)%n?v%n>c%n&1:v>c|2],o+=d):o+=4,o=v='')&&o

Try it online!

J, 44 41 bytes
;@(2<@(_,~[:I.0>.-,-~)/\0,]#:~_,[)97|3&u:

Try it online!
All credit to ngn for the best part: the self-append of the negative delta and max with 0, as a way of creating unique markers for each direction.
Separately, -3 bytes thanks to ngn for some line edits
2 = D, 3 = R, 0 = U, 1 = L, _ = select

97|3&u: turns the letters into numbers, with a = 0.
]#:~_,[ use a mixed base of infinity and the left arg as a way of calculating divmod
0, append 0 so we'll have a delta to the first letter
2<@(_,~[:I.0>.-,-~)/\ calculates the deltas, then append their negative, use J's "indices" (like k's "where" -- see ngn's answer), append an infinity _,~, and box the result <@.
;@ remove all the boxing

97-~ -> 97|

_&,@[#:] -> ]#:~_,[

([:; -> ;@(

@ngn Tyvm, I was hoping you'd have a look.

Jelly, 24 20 bytes
O_97ŻdZIb1Ḥ2¦Z;€3Fḟ0

Try it online!
A dyadic link taking the word as the left argument and the width as the right. Returns a list of integers where:
-2 = L
-1 = U
 1 = R
 2 = D
 3 = Select

C (gcc), 165 164 140 138 137 135 bytes
#define W(b,c);for(;X b;putchar(c))
x,y,X;f(s,w)char*s;{x=y=0 W(=*s++,33){X-=97 W(%w<x,76)x--W(%w>x,82)x++W(/w<y,85)y--W(/w>y,68)y++;}}

Try it online!
1 25 27 28 byte shaved off thanks to ceilingcat!
Ungolfed:
int x, y, X, Y;

f(char *s, int w) {
   x = 0;                                 // Starting position is (0, 0)
   y = 0;

    while (*s) {                          // For each character
        X = (*s - 'a') % w;               // Get its x coordinate
        Y = (*s - 'a') / w;               // Get its y coordinate
        s++;

        while (X > x) putchar('R'), x++;  // Print R for each step we need to move right
        while (X < x) putchar('L'), x--;  // ...et cetera...
        while (Y > y) putchar('D'), y++;
        while (Y < y) putchar('U'), y--;

        putchar('!');                     // We are there, print !
    }
}

Python 3, 126 bytes
lambda s,n:[abs(x//n-y//n)*'UD'[y>x]+abs(x%n-y%n)*'LR'[y%n>x%n]+'!'for x,y in zip(map(O,'a'+s),map(O,s))]
O=lambda c:ord(c)-97

Try it online!

05AB1E, 20 bytes
AIk0šI‰ü-εεdDNOyÄ×]»

Try it online!
Uses 0 for D, 1 for R, 2 for U, 3 for L, and newline for !. Space is used as an optional separator.

Charcoal, 52 48 bytes
Ｎθ≔⁰δＦＥＳ⌕βι«≔⁻﹪ιθ﹪δθη≔⁻÷ιθ÷δθζＦ±ηLＦ±ζUＦηRＦζD≔ιδ!

Try it online! Link is to verbose version of code. Edit: Saved 4 bytes by only tracking the alphabet index rather than the row and column separately. Takes input as X first, then the word. Explanation:
Ｎθ

Input X.
≔⁰δ

Start the path at the a with index 0.
ＦＥＳ⌕βι«

Input the word, convert its letters to their alphabet index and loop over them.
≔⁻﹪ιθ﹪δθη

Calculate the horizontal difference.
≔⁻÷ιθ÷δθζ

Calculate the vertical difference.
Ｆ±ηLＦ±ζUＦηRＦζD

Turn those differences into a path.
≔ιδ

Update the current index.
!

Select the current letter.
The reverse program is only 23 bytes:
ＮθＰ⪫⪪βθ¶ＦＳ≡ι!⊞υＫＫＭ✳ι⎚↑υ

Try it online! Link is to verbose version of code. Explanation:
Ｎθ

Input X.
Ｐ⪫⪪βθ¶

Split the lowercase alphabet into substrings of length X and print them on separate lines without moving the cursor.
ＦＳ

Loop over the command characters.
≡ι!

If the next character is a !...
⊞υＫＫ

... then save the letter under the cursor in a list...
Ｍ✳ι

... otherwise move in the direction given by that character.
⎚↑υ

Remove the alphabet and output the saved letters.


text:
Restricted-source polyglot string
Your goal is to write a program that prints the string abc in two languages. However, while the full code will print abc in one language (we'll call it Language 1), the other one (Language 2) must print abc if (and only if) every other character is skipped starting from the second character. If the full code is run in language 2, it must throw an error. If the skipped code is run in language 1, likewise, it must throw an error.
Rules and Clarification

Trailing newlines are allowed.
Output must be lowercase.
"Run" means compiled for compiled languages.
We will define "throwing an error" as outputting nothing to STDOUT and something to STDERR.

Test Cases
Language 1: 12345 -> abc
Language 1: 135 -> error
Language 2: 135 -> abc
Language 2: 12345 -> error

Scoring
The shortest code in bytes wins (the full code, not the skipped code).
Edit: I have clarified the rules based on feedback in the comments. The existing answers should still be valid.

Is trailing whitespace allowed in the output?

What precisely counts as an error? Is outputting nothing to STDOUT and something to STDERR sufficient? Consider this potential submission, where the Foo program that "errors" encounters an error that doesn't cause the program to halt, but it has no other output.

Are we to interpret "run" as "compiled" for compiled languages? Otherwise the implication would be that both shortened and full programs must compile in both languages, but throw run-time errors upon execution if the wrong length.

Can we output in uppercase (ABC instead of abc)?

brainfuck, 28 26 bytes
a+b[c-/[/---<]>>- ]<-.+.+.

Try it online!
Got the bf code from here.
Fails in Ink due to Expected target for new thread but saw '.+.+.'.
ink
abc//-<>-]-++

Try it online!
Ink will just print abc and the rest is a comment.
Fails in brainfuck due to mismatched bracket.

Keg, 21 19 bytes (19 17 characters)
abc#1 / ╘ " a b c

Try it online!
Simply prints abc and the rest is a comment.
Fails in MathGolf due to an undefined operator overload of /. / can not work on an integer (1) and a string( pushed via the space instruction.)
MathGolf
ac1/╘"abc

Try it online!
Does a bunch of nonsense, then ╘ deletes the whole stack. "abc pushes abc and the stack has an implicit output.
Fails in Keg due to the failure of implicit-outputting a floating-point number in its character form.

Welcome to Keg!

Japt and Pyth, 20 bytes
Both are shortenings of common scripting languages, nice
Japt: "_a_b_c_"v ë2,1  +[] (TIO, error in Pyth)
Pyth: "abc" 21 [ (TIO, error in Japt)

CJam and Gaia, 15 bytes
(CJam only cares about printable ASCII, so Gaia's codepage can be used to encode both programs)
Full:
 'a'b'c'” 'ọ;e<

Works in CJam
Errors in Gaia
Reduced:
 abc”'ọe

Works in Gaia
Errors in CJam
Explanation
This takes some advantage of the fact that ' defines a character literal in both languages.
Full program:
We push 5 characters: a, b, c, ”, and ọ. ; deletes the ọ and e< leaves the minimum of c and ”, which is c. The remaining characters (abc) are joined together and output implicitly.
In Gaia, everything up to ” is a string literal. We then push the char ọ, and then copy (;) the string literal back to the top and attempt to eval it (e). This throws an error because the last character in that string is ', which is improper syntax (a character literal after it is expected).
Reduced program:
” (or, more specifically, byte 0xFB) is not defined, so the program terminates with an error.
In Gaia we get the string literal  abc (with leading space). We then push the character ọ and eval it, which is the command for trim. This leaves plain abc on the stack, which is implicitly output.

naz / 7, 54 bytes
6a6a5a5m1a5a1a5a1o5s1a5a1o5s1a5a1o0m3a4a1a2a2a7a4a0a3a

This has to be the most esoteric answer I've submitted so far.
Explanation of the full code (works in naz)
6a6a5a5m1a5a1a5a     # Set the register to a value of 97 ("a")
1o                   # Output once
5s1a5a1o             # Output "b"
5s1a5a1o             # Output "c"
0m3a4a1a2a2a7a4a0a3a # Extra arithmetic to allow for a valid 7 program

Fails in 7: 6 command run with no bar in the frame at /opt/7/7.pl line 605, <> chunk 1.
The reduced code (works in 7)
665515151515151510341227403

Try it online!
Fails in naz: error: attempt to chain number literals
I can't give a very accurate explanation of the reduced code due to my relatively poor understanding of 7. I invite anyone who can make sense of it to improve this post.

PHP and Emoji, 21 chars, 30 bytes
Full:
⛽_a_b_c_➡➡;echo abc;

Skipped:
⛽abc➡eh b;

PHP, Full - Try it online! Prints: abc
Emoji, Skipped - Try it online! Prints: abc
PHP, Skipped - Try it online! Error: PHP Parse error:  syntax error, unexpected 'b' (T_STRING)
Emoji, Full - Try it online! Error: IndexError: pop from empty list

JavaScript (V8) and PHP, 29 bytes
Full:
print`abc`;'e_c_h_o_ _a_b_c';

Skipped:
pitac;echo abc;

JavaScript, Full - Try it online! Prints: abc
PHP, Skipped - Try it online! Prints: abc
JavaScript, Skipped - Try it online! Error: SyntaxError: Unexpected identifier
PHP, Full - Try it online! Error: abc: command not found

C++ (gcc) / C (gcc), 87 bytes
Full (C++)
//*
#import<cstdio>
main(){puts("abc"/*//
m_a_i_n_(_)_{_p_u_t_s_(_"_a_b_c_"_/*/

) ; }

Skipped (C)
/*#motcti>mi({us"b"*/main(){puts("abc"//
);}

Full C++, Working
Skipped C++, Error
Full C, Error
Skipped C, Working

Backhand and ><>, 39 bytes
Full
8.cv*c0*~]!]/]:::[@:1[+ooo2o+@o.3.+.o.;

Prints abc in Backhand
Errors in ><>
Skipped
8c*0~!/::@1+o2+o3+o;

Prints abc in ><>
Errors in Backhand
Explanation
Backhand doesn't execute the instructions one by one. In the full version, it goes 3, then the v instruction turns it to two steps. In the skipped version, this has the consequence that only the first instruction overlaps with the full version.
When you run the skipped version on Backhand, it divides by zero. Errors in backhand don't stop the program, so I added a stop command, which makes ><> a bit harder. (It's still a command in ><>, just not a good one.)
><>, on the other hand, does not skip instructions. In the full version, a . means jump. Fish is a 2D language, so it pops two arguments. However, only 1 thing was pushed (because of 8). Thus, something smells fishy....
How I get around some of the commands in ><> is simple. When 0 is executed, it pushes 0, then it immediately removes it. Then it skips the next command, which is a mirror. Finally, it duplicates twice, meaning 3 of the same thing is in the stack, which means @, which cycles the top 3 items in the stack, does absolutely nothing.

Hi! Welcome to CGCC! I hope you enjoy your stay!

An interesting way of doing it, but both ><> and Backhand have the " operator, which should make it a lot easier to push strings. You can do something like this for 29 bytes, though I'm sure that's easily golfable, perhaps by swapping the two languages

I only found out about backhand having it after I made this.

Errors in backhand don't stop the program, uhh, they do though

Turing Machine Code and Whitespace, 85 bytes
Full
 	 0 _	a	r 1 ; ; ;	;

 1 _ b r 2	;	; ; ; ;	; ;

 2 _ c * 3	;	; ; ; ;	;	;
	;
 ; ;

Works in Turing Machine Code
Errors in Whitespace: Prelude.!!: index too large
Reduced

Works in Whitespace
Errors in Turing Machine Code: Halted. No rule for state '0' and symbol '_'.
Takes advantage of the fact that Turing Machine Code ignores most white space and Whitespace pretty much ignores everything else.

GolfScript / MathGolf, 15 bytes
Here is a golfing language one in pure ASCII. (I guess the best score possible is 15 bytes...)
"abc"#; " a b c

Try it online!
GolfScript explanation
"abc"           # Start a string
     #          # Create a comment (rest is a comment)
      ; " a b c

MathGolf explanation
"abc"           Start a string
     #;         Perform expoentiation between the string and the input (implicitly a string)
                This isn't defined yet, so it throws an error
                Discarding the value won't be executed
        " a b c So does this

MathGolf/GolfScript, 8 bytes
"b";"abc

Try it online!
MathGolf Explanation
"b";     # Push b and then discard the value
    "abc # Push abc and then implicitly print

GolfScript explanation
"b";     # Push b and then discard the value
    "abc # Unterminated string, throws an error

Python 3 and Befunge-98, 36 bytes
z= print("@ , , , ""a b c "[8: :2] )

Works in Python:
z= print("@ , , , ""a b c "[8: :2] )

         "@ , , , "                  #String literal
                   "a b c "          #The second string literal is concatenated to the first
                           [8: :2]   #Extract every other character starting from index 8, which gives us "abc"
   print(                          ) #Print that and return None
z=                                   #Assign the result (None) to the variable z

Errors in Befunge:
z= print("@ , , , ""a b c "[8: :2] )

z     #No-op
 =    #Execute "" (raises an error in both FBBI and PyFunge)

Every other character
z rn(@,,,"abc"8 2

Errors in Python
The code is nowhere close to anything resembling valid Python syntax, so it raises a SyntaxError.
Works in Befunge:
z rn(@,,,"abc"8 2

z                  #No-op
  r                #Reverse direction
z                  #No-op
              8 2  #Push 2 and 8 (which we don't care about) onto the stack
         "abc"     #Push "cba" onto the stack
        ,          #Print the top of the stack ("a")
       ,           #Print the top of the stack ("b")
      ,            #Print the top of the stack ("c")
     @             #End the program

Rust / Python 3, 70 bytes
Full (Rust)
const _:i8= 3;//1 ; p r i n t ( " a b c " ) #
fn main(){print!("abc")}

Skipped (Python):
cnt_i=3/1;print("abc")#f an)pit(ac)

Rust fails on the skipped version with
error: unexpected closing delimiter: `)`
 --> a.py:1:28
  |
1 | cnt_i=3/1;print("abc")#f an)pit(ac)
  |                            ^ unexpected closing delimiter

error: aborting due to previous error

And Python fails on the full version with
  File "a.rs", line 1
    const _:i8= 3;//1 ; p r i n t ( " a b c " ) #
          ^
SyntaxError: invalid syntax

The Rust comment is turned into a division when one of the slashes disappears; the rest is fairly straightforward. I also avoided a compiler warning by naming the useless variable ‘_’.

05AB1E / MathGolf, 13 bytes/bytes
"aabbccc"1FÙ;

Try it online in 05AB1E (outputs abc).
Try it online in MathGolf (errors).
Every second character:
"abc"F;

Try it online in 05AB1E (errors).
Try it online in MathGolf (outputs abc).
Explanation:
# Full program in 05AB1E:
"aabbccc"     # Push string "aabbccc"
         1F   # Loop 1 time:
           Ù  #  Uniquify the top of the stack
            ; #  Halve it (no-op on strings)
              # (after the loop, the top of the stack is output implicitly)

# Full program in MathGolf:
           Ù  # Errors during compilation, because `Ù` isn't part of its known character-
              # set from the MathGolf codepage

# Reduced program in 05AB1E:
"abc"         # Push string "abc"
     F        # Loop that many times, which results in an error because it isn't an integer

# Reduced program in MathGolf:
"abc"         # Push string "abc"
     F        # Push builtin integer 17
      ;       # Discard the top of the stack
              # (after which the entire stack joined together is output implicitly as result)

Ruby & Perl 5 + -M5.10.0, 29 bytes
s=a=y=$> .write  a=?a ,?b ,?c

abc in Ruby,
error in Perl
This sets the variables s, a and y to the result of writeing a=?a ,?b, ?c (equivalent to 'abc' as ? defines a character literal and write accepts multiple arguments) to $> ($> points to STDOUT by default).
say$ wie =a,b,c

abc in Perl,
error in Ruby
This calls say with $ wie =a,b,c, which sets $ wie to the bareword a and  passes the barewords b and c.


text:
Backwards Alphabet Triangle
Without taking any input, output this exact text:
                         A
                        B A
                       C B A
                      D C B A
                     E D C B A
                    F E D C B A
                   G F E D C B A
                  H G F E D C B A
                 I H G F E D C B A
                J I H G F E D C B A
               K J I H G F E D C B A
              L K J I H G F E D C B A
             M L K J I H G F E D C B A
            N M L K J I H G F E D C B A
           O N M L K J I H G F E D C B A
          P O N M L K J I H G F E D C B A
         Q P O N M L K J I H G F E D C B A
        R Q P O N M L K J I H G F E D C B A
       S R Q P O N M L K J I H G F E D C B A
      T S R Q P O N M L K J I H G F E D C B A
     U T S R Q P O N M L K J I H G F E D C B A
    V U T S R Q P O N M L K J I H G F E D C B A
   W V U T S R Q P O N M L K J I H G F E D C B A
  X W V U T S R Q P O N M L K J I H G F E D C B A
 Y X W V U T S R Q P O N M L K J I H G F E D C B A
Z Y X W V U T S R Q P O N M L K J I H G F E D C B A

Rules

Output can be given by any convenient method.
You can print it to STDOUT or return it as a function result.
Either a full program or a function are acceptable.
A single trailing newline is acceptable, but no other formatting changes are allowed.
Capital letters are required.
Standard loopholes are forbidden.
This is code-golf so all usual golfing rules apply, and the shortest code (in bytes) wins.

A single trailing newline is acceptable, but no other formatting changes are allowed. So a trailing space on each line would not be permitted?

@DJMcMayhem Correct - no trailing spaces. Darn that rules out [char][space] times length, doesn't it? ;-)

Can we return a list of strings?

@NickKennedy Yes, that's fine.

I like the 3d bump effect around the J.

@NickKennedy You might be interested to know that output as a list of lines is now an accepted default IO method

Haskell, 53 bytes
[tail$do c<-reverse a;' ':[c|c<=d]|d<-a]
a=['A'..'Z']

Try it online!
This uses that each line has exactly 25 spaces. So, instead of separately handling the prefix spaces and the spaces between letters, we take 26 spaces, and decide whether to put a letter after each. This unfortunately gives one extra leading space, which we remove.

54 bytes
foldl(\m c->map(' ':)m++[c:' ':last m])["A"]['B'..'Z']

Try it online!

55 bytes
"A"%['B'..'[']
s%(h:t)=((' '<$t)++s):(h:' ':s)%t
s%_=[]

Try it online!

C (gcc),  82 79 77 75  74 bytes
Saved 2 bytes thanks to @ceilingcat
Saved 1 byte thanks to @gastropner
Derived from my 2nd JS answer.
f(x,y,s){for(x=0,y=25;~y;putchar(s>51?x=!y--,13:s&x>y?90-s/2:32))s=++x+y;}

Try it online!
How?
We start with \$x=0\$ and \$y=25\$. We increment \$x\$ at the beginning of the line. We set \$x\$ to \$0\$ and decrement \$y\$ at the end of the line, which is reached when \$x+y=52\$. We stop when \$y=-1\$.
This gives:
   0        1         2         3
   123456789012345678901234567890...
25 .........................A
24 ........................B.A
23 .......................C.B.A
22 ......................D.C.B.A
21 .....................E.D.C.B.A
 ⋮

We append a letter when \$x+y\$ is odd and \$x\$ is greater than \$y\$, or a space otherwise.
The ASCII code of the letter at \$(x,y)\$ is given by:
$$90-\left\lfloor\frac{x+y}{2}\right\rfloor, (x+y)\equiv 1 \pmod 2$$

74 bytes

Charcoal, 7 9 bytes
ＵＴ↙Ｅα…α⊕κ

Try it online! Link is to verbose version of code. Explanation:
  α     Uppercase alphabet
 Ｅ      Map over characters
    α   Uppercase alphabet
   …    Truncated to length
      κ Current index
     ⊕  Incremented
↙       Output with a 135° rotation

Effectively, this starts with the A in the bottom right corner, then works its way to the top left printing longer and longer prefixes of the uppercase alphabet each time, each prefix being printed towards the bottom left. The ＵＴ simply suppresses Charcoal's default rectangular output, apparently needed for this question for some reason.

V (vim), 16, 15, 12 bytes
¬ZAòé hòòxâÄ

Try it online!
Hexdump:
00000000: ac5a 41f2 e920 68f2 f278 e2c4            .ZA.. h..x..

Thanks to Kritixi Lithos for helping me golf a few off.
Explanation:
¬ZA                 " Insert every character between 'Z' and 'A'
                    " The cursor is on the 'A'
   ò         ò      " Recursively...
    é<space>        "   Insert a space
            h       "   Move back one character
                    "   If we're on the first column, this will break the loop
              ò     " Recursively...
               x    "   Delete the current character
                â   "   Stop looping if there's only one non-whitespace character on this line
                 Ä  "   Duplicate this line upward

Hint for 14b: you can do better than Ó

@KritixiLithos I'll see your 14, and raise you 12 :)

Nice, didn't know about â (looks like there are a few other similar ones in normal_keys.vim)

Does this count as 12 bytes though? 12 characters, yes. Same goes for the answer of Neil: https://codegolf.stackexchange.com/a/194860/90048

@D.Kovács Yes, it is exactly 12 bytes. See the hexdump I provided

Bash + common GNU tools, 42
echo {Z..A}|sed -n ':l;p;s/[B-Z]//;tl'|tac

Explanation

echo {Z..A} is a bash brace expansion that outputs Z Y X W V U T S R Q P O N M L K J I H G F E D C B A
The sed expression is a loop that:

:l  Define a label l
print the current pattern space
s/[B-Z]// match the first instance of B-Z and replace it with ""
tl if a match occurred above, jump back to label l
(implicit) otherwise quit.  -n suppresses implicit output of the pattern space at the end of line processing.

The output of the sed is the required triangle, but upside down.  The tac reverses it line-by-line to give the required output.

Try it online!

-1:
echo {Z..A}|sed ':l;/[B-Z]/p;s///;tl'|tac

@jnfnt Thanks.  I see that it does work, but so far I haven't been able to figure out how.  In particular the s/// appears to be deleting the first B-Z letter in the pattern space - but how does that work?

If the pattern between the first two slashes after "s" is empty, sed will assume you want to use the previous regular expression that was used.
(From https://www.gnu.org/software/sed/manual/html_node/Addresses.html:
"The empty regular expression ‘//’ repeats the last regular expression match")

Poetic, 686 bytes
the a-b-c corner
i was a child of ten or eleven
i said i am smart,i am likely to get an answer
i got a chance to read papers,novels or some old poetry
i read in class
as i read,i paused a bit
the words,i do admit,were a huge issue
please tutor,i said,i desire a nap
i truly do not
i fibbed
i am hiding a r-real g-great l-lie,a secret
i am idiot,i cant t-truly r-r-read
i think im reading,really im no smart reader
i need a lesson,i say,i really do
not a whole lot of people are helping teach me
i want a tutor,i say,i really want someone smart
i call a skilled tutor on my phone
as i call a person,i see a letter key,then i press down
it worked!i see a letter shape
amazing start for me

Try it online!
Poetic is an esolang I made in 2018 for a class project. It's basically brainfuck with word-lengths instead of symbols.

Woah neat language!

I like how typos of missing spaces are intentional

The spaces are missing only because I'm golfing this language. Usually, programmers of Poetic are encouraged to use spacing and punctuation freely (and use words more than 10 letters long for those pesky runs of small numbers ;) ).

J, 34 bytes
((32#~26-#)<@u:@,32,@,.65+|.)\i.26

Try it online!

PowerShell, 37 bytes
25..0|%{' '*$_+[char[]]((90-$_)..65)}

Try it online!

R, 78 72 63 bytes
for(i in 1:26){cat(strrep(" ",26-i));cat(LETTERS[i:1],fill=52)}

Try it online!
Nothing fancy. First print spaces, then print letters.
Improvement inspired by https://codegolf.stackexchange.com/a/195078/89953, but cannot comment there because of reputation.

Python 2, 53 bytes
i=26
s='A'
while i:i-=1;print' '*i+s;s='%c '%(91-i)+s

Try it online!
We take care not to introduce any trailing spaces, which means avoiding center and also avoiding adding a space with A for the first row.

Ruby, 57 54 bytes
?A.upto(?Z){puts' '*(90-_1.ord)+[*?A.._1].reverse*' '}

Attempt This Online!

You can save one byte by moving puts inside (?A..?Z).map{|c|puts' '*(90-c.ord)+[*?A..c].reverse*' '}

Python 3, 76 75 bytes:
-1 byte thanks to @pppery
for i in range(27):print((27-i)*' '+' '.join(chr(64+i-x)for x in range(i)))

Try it online.
Another 75 bytes:
for i in range(27):print(' '.join(chr(64+i-x)for x in range(i)).center(51))

Try it online.

You can remove the space in chr(65+x) for x in ....

@pppery it have been fixed. tnx.

Canvas, 13 bytes
Ｚ［± ＊ＺＬ³－ ××］

Try it here!
Explanation:
Z[± *ZL³- ××]
Z[          ] map over the prefixes of the uppercase alphabet
  ±             reverse the current prefix
    *           interleave it with spaces
     ZL³-       substract the loop index from 26
          ×     that many spaces
           ×    prepend the spaces to the prefix

7 bytes with padding with spaces. yep, 2x bytecount to "remove" them..

Alternate 7 byter with space padding

Wolfram Language (Mathematica), 76 bytes
Array[StringRiffle[Reverse@ToUpperCase@Alphabet[][[;;#]]]&,26]~Column~Center

I don't think this answer meets the specifications of the challenge as written, since the correct output includes literal rows of spaces. The shortest compliant version I can come up with is 83 bytes (including a golf of the row generation): StringRiffle[PadLeft[Capitalize@Alphabet[][[#;;1;;-1]]&~Array~26]/. 0->"","~"," "]&, replacing the ~ with a literal newline. Note that the space in /. 0 is necessary.

Jelly, 13 bytes
ØALḶ⁶ẋṚżUK$ƤY

Try it online!
A full program that prints the desired output to STDOUT.
Explanation
ØA            | Uppercase letters
  L           | Length (26)
   Ḷ          | Lowered range (0..25)
    ⁶ẋ        | Space that many times (vectorises)
      Ṛ       | Reverse list
       ż      | Zip with:
          $Ƥ  | - Following applied to each prefix of the uppercase letters:
        U     |   - Reverse
         K    |   - Join with spaces
            Y | Join with newlines

Without the final Y, a list of lists of Jelly strings woulf be returned, with the spaces and letters in separate sublists. As such, I’ve gone with joining the outer list with newlines and relying on Jelly’s default printing method to produce the correct output.

As outputting a list of lines is acceptable, you can remove the Y

@cairdcoinheringaahing The issue is that the output would be a list of lists of strings because of the ż, and it’s only by virtue of Jelly’s outputting to STDOUT that it looks ok.

As strings are the same as char arrays (which are generated by your program) in Jelly, I'd argue that the output constitutes a list of lines. However, it's entirely up to you whether to accept that argument or not.

@cairdcoinheringaahing The issue is it doesn’t return a list of character arrays, but a list of lists of two character arrays each - the spaces and letters are in separate sub lists. I’ve previously been told by more experienced golfers that such a return type wouldn’t be permitted, and so I’ve gone with the output to STDOUT. Replacing ż with ;" would resolve the issue, but I’d then still be at 13 bytes without the Y.

Retina 0.8.2, 57 52 42 bytes
T`L`_L
}`^
Z
.
$.`$* $&$'¶
\B\w
 $&
O`
G`.

Try it online! Explanation:
T`L`_L

Move all of the letters so far one step backwards in the alphabet, but delete any A.
^
Z

Prefix a Z to the current string.
}`

Repeat the above until the transformation becomes idempotent. This happens when the string is the entire alphabet; the A is deleted, the Z-B get transliterated into Y-A, and another Z is prefixed.
.
$.`$* $&$'¶

Turn the alphabet into a triangle.
\B\w
 $&

Space out the letters.
O`

Get the lines in the correct order.
G`.

Remove an extraneous trailing newline. (Retina 0.8.2 always adds a trailing newline, so there would have been two; had I used Retina 1 I could have claimed that newline as my allowed newline.)

Forth (gforth), 62 bytes
: f 25 for i spaces 25 i - for i 65 + emit ."  "next cr next ;

Try it online!
Code explanation
: f            \ start a new word definition
  25 for       \ loop from 25 to 0
    i spaces   \ print loop-index spaces
    25 i - for \ loop from (25 - loop-index) to 0
      i 65 +   \ add inner loop-index to 65 (ascii 'A')
      emit     \ output ascii char for value
      ."  "    \ output a single space
    next       \ end inner loop
    cr         \ output a newline
  next         \ end outer loop
;              \ end word definition

Japt -R, 14 bytes
;Båi ®¬¸Ãû
mx1

Saved a byte thanks to @Shaggy.
Gained 4 bytes due to fixing a bug.
Test it

rPS can be ¬¸.

@dzaima Fixed now

K (oK), 34 33  bytes
-1 byte thanks to ngn
(-26-!26)$`c${,/32,'|65+!x}'1+!26

Try it online!

\c$'->`c$`

@ngn Thank you! I should have tried it myself :)

ah, i missed this submission. mine is an awful lot like this but in k4 ...

@scrawl Your solution is much shorter them mine :)

K (ngn/k), 27 bytes
1_|^\(," "/+,a),a:`c$90-!26

Try it online!
!26 is 0 1..25
90-!26 is 90 89..65
`c$ convert to chars: "ZY..A"
a: assign to a
(,..), prepend as a single element

+,a flip enlist, i.e. make each char a length-1 string: (,"Z";,"Y";..;,"A")
" "/ join with spaces (in some dialects of k this may be " "/:)

^\ without-scan, i.e. start with "Z Y..A", then remove "Z", then remove "Y", etc, and collect intermediate results
| reverse
1_ drop the first, as it's an all-spaces string

This outputs with parens and quotes. I don't think that's allowed.

@pppery "You can print it to STDOUT or return it as a function result."

Sorry, not very familiar with the K language, and the fact that this does produce output when run as a full program confused me.

@pppery no worries. k tries to print objects in such a way that feeding the output back into the interpreter produces an equivalent object. in this case ( ) is a \n-separated list (or equivalently, it could be ;-separated) of "strings".

@pppery many languages print the result of a line by default. this is especially common among golfing languages, but also present in some practical languages like apl and its family, which k is a member of.

What dialect of K would you suggest for learning the language?

@Jonah my favourite is k5/k6 (these were very similar, so i consider them a single dialect), which is what oK and ngn/k follow. oK has a nice manual and interactive examples. unfortunately the real k5 and k6 never saw the light of day.

Thanks for the links @ngn

@Jonah if you intend to get a job - k4 is still widely used in the form of kdb+ and q, so it might be worth learning. there are some learning materials about it at kx systems' website. 32-bit k4 is free for non-commercial use. kona follows the older k3. the newest "shakti", also known as k7, is still being designed; it might change significantly before it's released. it's followed by ktye/i.

Java (JDK), 82 bytes
v->{var x="";for(char c=64;++c<91;)System.out.printf("%"+(c-38)+"s%n",x=c+" "+x);}

Try it online!
Credits

-2 bytes thanks to Kevin Cruijssen.

82 bytes

05AB1E, 8 bytes
ASuηí».c

Try it online!
A           # push the alphabet, "abcdefghijklmnopqrstuvwxyz"
 S          # split to a list of chars
  u         # uppercase
   η        # prefixes
    í       # reverse each
     »      # join by newlines, joining sublists by spaces
      .c    # center

Here is an alternative 8 bytes solution. Same idea and same bytecount, but uses fewer commands.

k4, 24 bytes
(-26-!26)$|:',\.Q.A,'" "

explanation:
               .Q.A,'" " /append space to each capital letter ("A ";"B "; "C "; ... )
             ,\          /join scan, join each element successively and return intermediate results ("A ";"A B ";"A B C "; ... )
          |:'            /reverse each
(-26-!26)$               /left-pad each with -26 -27 -28 ...

run like:
q)k)(-26-!26)$|:',\.Q.A,'" "
"                         A"
"                        B A"
"                       C B A"
"                      D C B A"
..

Retina, 35 bytes

25*

.
Y`.`RL
L^$w`^(..)*
$#1* $'

Try it online! Explanation:

25*

Insert 25 spaces.

.

Insert .s in all available positions. This results in 26 .s, because both the start and end can have a . inserted.
Y`.`RL

Cyclically transliterate the .s using a reversed uppercase alphabet.
L^$w`^(..)*

List all (necessarily overlapping) prefixes of even numbers of characters, in reverse order (i.e. longest prefix to shortest).
$#1* $'

For each prefix, output the number of pairs as a run of spaces (effectively deleting the letters) plus its suffix.

Scratch, 256 240 bytes
-16 thanks to @Lyxal because I can't read! XD
Try it online!
At first, I thought it would be shorter to add each string manually, but I was very wrong! It doesn't look very good outside of monospace fonts though...
delete all of[P v
set[A v]to[ABCDEFGHIJKLMNOPQRSTUVWXYZ
set[C v]to(25
set[L v]to(
repeat(26
set[S v]to(
repeat(C
set[S v]to(join(S)(
change[C v]by(-1
set[L v]to(join(join(letter(round((length of(L))/(2)))of(A))( ))(L
add(join(S)(L))to[P v

Hey so just a heads up - consider submitting a function instead of a full program, as define is shorter than when gf clicked, and it removes the need for the painful length of ask()and wait

vim, 42 41 bytes
:set nf=alpha
aZ<ESC>qqYp<C-x>q24@qVggJqqYPxq24@q

<ESC> is 0x1b, <C-x> is 0x18, <NL> is 0x0a.
Annotated
:set nf=alpha   # make <C-x> work with letters
aZ<ESC>         # put Z in buffer
qqYp<C-x>q      # Record macro q: Append a line with the previous letter
24@q            # ...and execute until we have all the letters
VggJ            # combine all lines into "Z Y X ... C B A"
qqYPxq         # Record macro q: Copy line to previous line, delete first char
24@q            # ...and execute until we have all the rows

Try it online!

SNOBOL4 (CSNOBOL4), 103 93 77 bytes
N	&UCASE B LEN(1) . B @X :F(END)
	A =B ' ' A
	OUTPUT =LPAD(A,26 + X) :(N)
END

Try it online!

Excel, 79 bytes
=LET(k,ROW(1:26),REPT(" ",26-k)&RIGHT(CONCAT(" "&CHAR(91-TRANSPOSE(k))),2*k-1))

Explanation
k,ROW                                                         ' k = 1..26
REPT(" ",26-k)&RIGHT(CONCAT(" "&CHAR(91-TRANSPOSE(k))),2*k-1) ' Final Calculation
REPT(" ",26-k)                                                ' 26-k spaces
                     CONCAT(" "&CHAR(91-TRANSPOSE(k)))        ' " Z Y ...
               RIGHT(                                 ,2*k-1) ' Right 2k-1 characters

JavaScript (Node.js),  65  63 bytes
Saved 2 bytes thanks to @l4m2
f=(n=26,s=`A
`)=>n--?''.padEnd(n)+s+f(n,Buffer([91-n,32])+s):''

Try it online!

JavaScript (Node.js), 79 bytes
More maths, more bytes.
f=(x=y=0)=>y<26?Buffer([x<y+26?y+x++&x>25-y?156-x+y>>1:32:(x=!++y,13)])+f(x):''

Try it online!

https://tio.run/##y0osSyxOLsosKNHNy09J/f8/zVYjz9bITKfYNsGRK0HT1i5PV9deXV2vIDHFNS9FI09Tu1g7TSNPx6k0LS21SCPa0lA3T8fYKBYormmlrv4/OT@vOD8nVS8nP10jTUNT8z8A

Zsh, 46 43 bytes
-3 bytes from @pxeger using eval instead of a for loop
eval a={A..Z}'\ $a;echo ${(l:26+i++:)a%?};'

Try it online!
The eval expands to:
a=A\ $a;echo ${(l:26+i++:)a%?}; a=B\ $a;echo ${(l:26+i++:)a%?}; ...

Which is the same as the for loop from the second 46-byte solution below:

Originals:
for c ({A..Z})a=($c $a)&&echo ${(l:25-i++:)}$a

Try it online!
Abuses arrays implicitly joining on spaces. l:expr: pads on the left with spaces until at expr characters wide. Putting parameter expansion flags with no parameter like this causes them to operate on an empty string.

Alternate 46 byte solution, using a string with ${a%postfixremoval} instead. Note that here we increment the padding width to accommodate the growing total string length.
for c ({A..Z})a=$c\ $a&&echo ${(l:26+i++:)a%?}

Try it online!

43: Try it online!

Python3, 91 bytes
for _ in range(26):print(f'{" ".join([*map(chr,range(65,91))][0:_+1][::-1]):^52}'.rstrip())

Try it online!
-1 byte thanks to @cairdcoinheringaahing

Welcome to the site! Just as a start, there are a few quick golfs that you can do, such as removing the space after the colon. I'd recommend linking to an online testing environment, such as Try it online!, so that others can verify and help you golf your solution

@cairdcoinheringaahing Thank you! Nice tips ;) and you just saved me one byte!

Your output has trailing spaces from the centering, which this challenge does not allow.

@xnor Nice catch! Fixed it!

Pyth, 20 bytes
VlGp*dt-lGNjdr_<GhN1

Pretty happy with this, since it's my first Pyth answer. Probably can be golfed a lot
Explanation
VlG   for N in range(26)

p*dt-lGN    26-N spaces outputted

    <GhN   First N alphabet characters
   _       Reversed
  r        Capitalised
j       1  Joined with spaces (space after each character)

Try it online!

C# (Visual C# Interactive Compiler), 81 bytes
var x="A";for(char y='\x41';++y<92;x=y+" "+x){WriteLine(new string(' ',91-y)+x);}

Try it online!

R, 65 bytes
for(i in 1:26){cat(strrep(" ",26-i));cat(LETTERS[i:1]);cat("\n")}

Try it online!

Red, 76 bytes
a:""repeat n 26[insert a rejoin[sp#"@"+ n]print next pad/left copy a n + 26]

Try it online!

Icon, 84 bytes
procedure main()
s:="";i:=1to 26&s[1:1]:=" "||char(64+i)&write(right(s,25+i))&\z
end

Try it online!

Python 3, 78 bytes
for i in range(26):print(' '*(25-i)+' '.join(chr(65+i-j) for j in range(i+1)))

A straightforward solution.

Perl 6, 33 bytes
{(' 'Xx(25...0))Z~[\R,] 'A'..'Z'}

Try it online!
Anonymous code block that returns a list of lines.
Explanation:
{                               }  # Anonymous code block
  ' 'Xx                            # String multiply spaces
       (25...0)                       # by the range 25 to 0
 (             )Z~                 # Zip these indents with
                  [\  ]               # The triangular reduced
                    R,                # Reversed list concatenation
                        'A'..'Z'      # Of the alphabet

Keg 32 31 30 26 25 24 25 bytes (SBCS)
A(\≤|:Z$- ⅍*,:Aɧ∑, ,)⑨
,)

Try it online!
Hey, Keg's coming 9th (at the time of writing)!
Contains unprintable characters. Uses the 26 byte approach but uses a space converted to a string to pad lines.
Answer History
25 bytes
A(|:Aɧ ⅍!3--*,∑, ,)1+
,

Try it online!
26 bytes (SBCS)
A(|:Aɧ(!;;-| ,)∑, ,)1+
,

-4 bytes by using stack mechanics rather than the register
Explained
A(␚|:Aɧ(␚!;;-| ,)∑, ,)1+¶,
A                           #Push "A" onto the stack
(␚|                         #26 times:
    :Aɧ                     #   Push a generated range from A to the top of stack
    (␚!;;-| ,)              #   Space-align the row
    ∑, ,)                   #   Print each character space seperated
    1+                      #   Increment the top letter by one
    ¶,                      #   Print a newline

Substitute ␚ for the actual unprintable control key and ¶ for a literal newline
30 bytes (SBCS)
A&(|A&:&ɧ(!;-| ,)(, ,)&1+&
,

Explained
A&(␚|A&:&ɧ(␚!;-| ,)(, ,)&1+&¶,
A&                              #Put A in the register
  (␚|                           #26 times:
      A&:&ɧ                     #   Push a generated range from A to the top of stack
           (␚!;-| ,)            #   Space-align the row
                    (, ,)       #   Print each character space seperated
                         &1+&   #   Increment the top letter by one
                             ¶, #   Print a newline

Substitute ␚ for the actual unprintable control key and ¶ for a literal newline
31 bytes (SBCS)
A&(\≤|A&:&ɧ(\≤!-| ,)(, ,)&1+&
,

Explained
A&(\≤|A&:&ɧ(\≤!-| ,)(, ,)&1+&¶,)
A&                              #Store A in the register
  (\≤|                          #26 times:
      A&:&ɧ                     #   Push a generated range from A to the top
           (\≤!-| ,)            #   Align it using spaces
                    (, ,)       #   Print the row
                         &1+&   #   Increment the letter
                             ¶,)#   Print a newline (replace ¶ w/ \n)

J, 31 bytes
(|.@;:inv,~' '#~26-#)\u:65+i.26

Try it online!

Julia 1.0, 51 bytes
[' '^i*join(('Z'-i:-1:'B').*' ')*'A' for i=25:-1:0]

Try it online!

44 bytes

APL (Dyalog Extended), 22 bytes
(⌽0,⍳25)⌽⌽↑{∊⍺' '⍵}\⎕A

Try it online!
Output of above function.
Explanation:

⎕A is the uppercase alphabet character vector.
{∊⍺' '⍵} is a 1 character shorter version of {⍺,' ',⍵} which puts a space between arguments ⍺ and ⍵.
Reducing / this function over ⎕A would result in the uppercase alphabet with spaces between, 'A B C ...'. Scanning \ instead produces a nested vector of all the intermediate results, ('A') ('A B') ('A B C')....
Mix ↑ turns the nested vector into a matrix, padding rows to equal length with spaces, which is then horizontally mirrored with ⌽ (the one on the right).
To get the final answer we need to rotate the rows (dyadic ⌽) by 25, 24, 23, ... 0 characters.
The left argument to the rotation is the sequence 25, 24, 23, ... 0, which is obtained concisely by ⌽0,⍳25.

Batch, 144 bytes
Abuses token delimiters ([ and ;)
@!! 2>nul||cmd/q/v/c%0&&exit/b
set;=for /l %%A in (65 1 90)do set[=
%;% ![!
%;%![:~,-1!&cmd/cexit %%A&set]=!=exitcodeascii! !]!&echo(![!!]:~,-1!

Sources

Golfing Delayed Expansion Variables in Batch
CMD.EXE parsing - Token Delimiters
Write HEX values to file in Windows batch

Deadfish~, 10394 bytes
{i}{i}{i}ii{c}{c}ccccc{i}{i}{i}iiic{{d}iiiii}dddddc{i}{i}ii{c}{c}cccc{i}{i}{i}iiiic{d}{d}{d}ddddc{i}{i}{i}iiic{{d}iiiii}dddddc{i}{i}ii{c}{c}ccc{i}{i}{i}iiiiic{d}{d}{d}dddddc{i}{i}{i}iiiic{d}{d}{d}ddddc{i}{i}{i}iiic{{d}iiiii}dddddc{i}{i}ii{c}{c}cc{i}{i}{i}iiiiiic{d}{d}{d}ddddddc{i}{i}{i}iiiiic{d}{d}{d}dddddc{i}{i}{i}iiiic{d}{d}{d}ddddc{i}{i}{i}iiic{{d}iiiii}dddddc{i}{i}ii{c}{c}c{{i}dddddd}dddc{{d}iiiiii}iiic{i}{i}{i}iiiiiic{d}{d}{d}ddddddc{i}{i}{i}iiiiic{d}{d}{d}dddddc{i}{i}{i}iiiic{d}{d}{d}ddddc{i}{i}{i}iiic{{d}iiiii}dddddc{i}{i}ii{c}{c}{{i}dddddd}ddc{{d}iiiiii}iic{{i}dddddd}dddc{{d}iiiiii}iiic{i}{i}{i}iiiiiic{d}{d}{d}ddddddc{i}{i}{i}iiiiic{d}{d}{d}dddddc{i}{i}{i}iiiic{d}{d}{d}ddddc{i}{i}{i}iiic{{d}iiiii}dddddc{i}{i}ii{c}ccccccccc{{i}dddddd}dc{{d}iiiiii}ic{{i}dddddd}ddc{{d}iiiiii}iic{{i}dddddd}dddc{{d}iiiiii}iiic{i}{i}{i}iiiiiic{d}{d}{d}ddddddc{i}{i}{i}iiiiic{d}{d}{d}dddddc{i}{i}{i}iiiic{d}{d}{d}ddddc{i}{i}{i}iiic{{d}iiiii}dddddc{i}{i}ii{c}cccccccc{{i}dddddd}c{{d}iiiiii}c{{i}dddddd}dc{{d}iiiiii}ic{{i}dddddd}ddc{{d}iiiiii}iic{{i}dddddd}dddc{{d}iiiiii}iiic{i}{i}{i}iiiiiic{d}{d}{d}ddddddc{i}{i}{i}iiiiic{d}{d}{d}dddddc{i}{i}{i}iiiic{d}{d}{d}ddddc{i}{i}{i}iiic{{d}iiiii}dddddc{i}{i}ii{c}ccccccc{{i}dddddd}ic{{d}iiiiii}dc{{i}dddddd}c{{d}iiiiii}c{{i}dddddd}dc{{d}iiiiii}ic{{i}dddddd}ddc{{d}iiiiii}iic{{i}dddddd}dddc{{d}iiiiii}iiic{i}{i}{i}iiiiiic{d}{d}{d}ddddddc{i}{i}{i}iiiiic{d}{d}{d}dddddc{i}{i}{i}iiiic{d}{d}{d}ddddc{i}{i}{i}iiic{{d}iiiii}dddddc{i}{i}ii{c}cccccc{{i}dddddd}iic{{d}iiiiii}ddc{{i}dddddd}ic{{d}iiiiii}dc{{i}dddddd}c{{d}iiiiii}c{{i}dddddd}dc{{d}iiiiii}ic{{i}dddddd}ddc{{d}iiiiii}iic{{i}dddddd}dddc{{d}iiiiii}iiic{i}{i}{i}iiiiiic{d}{d}{d}ddddddc{i}{i}{i}iiiiic{d}{d}{d}dddddc{i}{i}{i}iiiic{d}{d}{d}ddddc{i}{i}{i}iiic{{d}iiiii}dddddc{i}{i}ii{c}ccccc{{i}dddddd}iiic{{d}iiiiii}dddc{{i}dddddd}iic{{d}iiiiii}ddc{{i}dddddd}ic{{d}iiiiii}dc{{i}dddddd}c{{d}iiiiii}c{{i}dddddd}dc{{d}iiiiii}ic{{i}dddddd}ddc{{d}iiiiii}iic{{i}dddddd}dddc{{d}iiiiii}iiic{i}{i}{i}iiiiiic{d}{d}{d}ddddddc{i}{i}{i}iiiiic{d}{d}{d}dddddc{i}{i}{i}iiiic{d}{d}{d}ddddc{i}{i}{i}iiic{{d}iiiii}dddddc{i}{i}ii{c}cccc{{i}dddddd}iiiic{{d}iiiiii}ddddc{{i}dddddd}iiic{{d}iiiiii}dddc{{i}dddddd}iic{{d}iiiiii}ddc{{i}dddddd}ic{{d}iiiiii}dc{{i}dddddd}c{{d}iiiiii}c{{i}dddddd}dc{{d}iiiiii}ic{{i}dddddd}ddc{{d}iiiiii}iic{{i}dddddd}dddc{{d}iiiiii}iiic{i}{i}{i}iiiiiic{d}{d}{d}ddddddc{i}{i}{i}iiiiic{d}{d}{d}dddddc{i}{i}{i}iiiic{d}{d}{d}ddddc{i}{i}{i}iiic{{d}iiiii}dddddc{i}{i}ii{c}ccc{{i}dddddd}iiiiic{{d}iiiiii}dddddc{{i}dddddd}iiiic{{d}iiiiii}ddddc{{i}dddddd}iiic{{d}iiiiii}dddc{{i}dddddd}iic{{d}iiiiii}ddc{{i}dddddd}ic{{d}iiiiii}dc{{i}dddddd}c{{d}iiiiii}c{{i}dddddd}dc{{d}iiiiii}ic{{i}dddddd}ddc{{d}iiiiii}iic{{i}dddddd}dddc{{d}iiiiii}iiic{i}{i}{i}iiiiiic{d}{d}{d}ddddddc{i}{i}{i}iiiiic{d}{d}{d}dddddc{i}{i}{i}iiiic{d}{d}{d}ddddc{i}{i}{i}iiic{{d}iiiii}dddddc{i}{i}ii{c}cc{{i}dddddd}iiiiiic{{d}iiiiii}ddddddc{{i}dddddd}iiiiic{{d}iiiiii}dddddc{{i}dddddd}iiiic{{d}iiiiii}ddddc{{i}dddddd}iiic{{d}iiiiii}dddc{{i}dddddd}iic{{d}iiiiii}ddc{{i}dddddd}ic{{d}iiiiii}dc{{i}dddddd}c{{d}iiiiii}c{{i}dddddd}dc{{d}iiiiii}ic{{i}dddddd}ddc{{d}iiiiii}iic{{i}dddddd}dddc{{d}iiiiii}iiic{i}{i}{i}iiiiiic{d}{d}{d}ddddddc{i}{i}{i}iiiiic{d}{d}{d}dddddc{i}{i}{i}iiiic{d}{d}{d}ddddc{i}{i}{i}iiic{{d}iiiii}dddddc{i}{i}ii{c}c{{i}ddddd}dddc{{d}iiiii}iiic{{i}dddddd}iiiiiic{{d}iiiiii}ddddddc{{i}dddddd}iiiiic{{d}iiiiii}dddddc{{i}dddddd}iiiic{{d}iiiiii}ddddc{{i}dddddd}iiic{{d}iiiiii}dddc{{i}dddddd}iic{{d}iiiiii}ddc{{i}dddddd}ic{{d}iiiiii}dc{{i}dddddd}c{{d}iiiiii}c{{i}dddddd}dc{{d}iiiiii}ic{{i}dddddd}ddc{{d}iiiiii}iic{{i}dddddd}dddc{{d}iiiiii}iiic{i}{i}{i}iiiiiic{d}{d}{d}ddddddc{i}{i}{i}iiiiic{d}{d}{d}dddddc{i}{i}{i}iiiic{d}{d}{d}ddddc{i}{i}{i}iiic{{d}iiiii}dddddc{i}{i}ii{c}{{i}ddddd}ddc{{d}iiiii}iic{{i}ddddd}dddc{{d}iiiii}iiic{{i}dddddd}iiiiiic{{d}iiiiii}ddddddc{{i}dddddd}iiiiic{{d}iiiiii}dddddc{{i}dddddd}iiiic{{d}iiiiii}ddddc{{i}dddddd}iiic{{d}iiiiii}dddc{{i}dddddd}iic{{d}iiiiii}ddc{{i}dddddd}ic{{d}iiiiii}dc{{i}dddddd}c{{d}iiiiii}c{{i}dddddd}dc{{d}iiiiii}ic{{i}dddddd}ddc{{d}iiiiii}iic{{i}dddddd}dddc{{d}iiiiii}iiic{i}{i}{i}iiiiiic{d}{d}{d}ddddddc{i}{i}{i}iiiiic{d}{d}{d}dddddc{i}{i}{i}iiiic{d}{d}{d}ddddc{i}{i}{i}iiic{{d}iiiii}dddddc{i}{i}iiccccccccc{{i}ddddd}dc{{d}iiiii}ic{{i}ddddd}ddc{{d}iiiii}iic{{i}ddddd}dddc{{d}iiiii}iiic{{i}dddddd}iiiiiic{{d}iiiiii}ddddddc{{i}dddddd}iiiiic{{d}iiiiii}dddddc{{i}dddddd}iiiic{{d}iiiiii}ddddc{{i}dddddd}iiic{{d}iiiiii}dddc{{i}dddddd}iic{{d}iiiiii}ddc{{i}dddddd}ic{{d}iiiiii}dc{{i}dddddd}c{{d}iiiiii}c{{i}dddddd}dc{{d}iiiiii}ic{{i}dddddd}ddc{{d}iiiiii}iic{{i}dddddd}dddc{{d}iiiiii}iiic{i}{i}{i}iiiiiic{d}{d}{d}ddddddc{i}{i}{i}iiiiic{d}{d}{d}dddddc{i}{i}{i}iiiic{d}{d}{d}ddddc{i}{i}{i}iiic{{d}iiiii}dddddc{i}{i}iicccccccc{{i}ddddd}c{{d}iiiii}c{{i}ddddd}dc{{d}iiiii}ic{{i}ddddd}ddc{{d}iiiii}iic{{i}ddddd}dddc{{d}iiiii}iiic{{i}dddddd}iiiiiic{{d}iiiiii}ddddddc{{i}dddddd}iiiiic{{d}iiiiii}dddddc{{i}dddddd}iiiic{{d}iiiiii}ddddc{{i}dddddd}iiic{{d}iiiiii}dddc{{i}dddddd}iic{{d}iiiiii}ddc{{i}dddddd}ic{{d}iiiiii}dc{{i}dddddd}c{{d}iiiiii}c{{i}dddddd}dc{{d}iiiiii}ic{{i}dddddd}ddc{{d}iiiiii}iic{{i}dddddd}dddc{{d}iiiiii}iiic{i}{i}{i}iiiiiic{d}{d}{d}ddddddc{i}{i}{i}iiiiic{d}{d}{d}dddddc{i}{i}{i}iiiic{d}{d}{d}ddddc{i}{i}{i}iiic{{d}iiiii}dddddc{i}{i}iiccccccc{{i}ddddd}ic{{d}iiiii}dc{{i}ddddd}c{{d}iiiii}c{{i}ddddd}dc{{d}iiiii}ic{{i}ddddd}ddc{{d}iiiii}iic{{i}ddddd}dddc{{d}iiiii}iiic{{i}dddddd}iiiiiic{{d}iiiiii}ddddddc{{i}dddddd}iiiiic{{d}iiiiii}dddddc{{i}dddddd}iiiic{{d}iiiiii}ddddc{{i}dddddd}iiic{{d}iiiiii}dddc{{i}dddddd}iic{{d}iiiiii}ddc{{i}dddddd}ic{{d}iiiiii}dc{{i}dddddd}c{{d}iiiiii}c{{i}dddddd}dc{{d}iiiiii}ic{{i}dddddd}ddc{{d}iiiiii}iic{{i}dddddd}dddc{{d}iiiiii}iiic{i}{i}{i}iiiiiic{d}{d}{d}ddddddc{i}{i}{i}iiiiic{d}{d}{d}dddddc{i}{i}{i}iiiic{d}{d}{d}ddddc{i}{i}{i}iiic{{d}iiiii}dddddc{i}{i}iicccccc{{i}ddddd}iic{{d}iiiii}ddc{{i}ddddd}ic{{d}iiiii}dc{{i}ddddd}c{{d}iiiii}c{{i}ddddd}dc{{d}iiiii}ic{{i}ddddd}ddc{{d}iiiii}iic{{i}ddddd}dddc{{d}iiiii}iiic{{i}dddddd}iiiiiic{{d}iiiiii}ddddddc{{i}dddddd}iiiiic{{d}iiiiii}dddddc{{i}dddddd}iiiic{{d}iiiiii}ddddc{{i}dddddd}iiic{{d}iiiiii}dddc{{i}dddddd}iic{{d}iiiiii}ddc{{i}dddddd}ic{{d}iiiiii}dc{{i}dddddd}c{{d}iiiiii}c{{i}dddddd}dc{{d}iiiiii}ic{{i}dddddd}ddc{{d}iiiiii}iic{{i}dddddd}dddc{{d}iiiiii}iiic{i}{i}{i}iiiiiic{d}{d}{d}ddddddc{i}{i}{i}iiiiic{d}{d}{d}dddddc{i}{i}{i}iiiic{d}{d}{d}ddddc{i}{i}{i}iiic{{d}iiiii}dddddc{i}{i}iiccccc{{i}ddddd}iiic{{d}iiiii}dddc{{i}ddddd}iic{{d}iiiii}ddc{{i}ddddd}ic{{d}iiiii}dc{{i}ddddd}c{{d}iiiii}c{{i}ddddd}dc{{d}iiiii}ic{{i}ddddd}ddc{{d}iiiii}iic{{i}ddddd}dddc{{d}iiiii}iiic{{i}dddddd}iiiiiic{{d}iiiiii}ddddddc{{i}dddddd}iiiiic{{d}iiiiii}dddddc{{i}dddddd}iiiic{{d}iiiiii}ddddc{{i}dddddd}iiic{{d}iiiiii}dddc{{i}dddddd}iic{{d}iiiiii}ddc{{i}dddddd}ic{{d}iiiiii}dc{{i}dddddd}c{{d}iiiiii}c{{i}dddddd}dc{{d}iiiiii}ic{{i}dddddd}ddc{{d}iiiiii}iic{{i}dddddd}dddc{{d}iiiiii}iiic{i}{i}{i}iiiiiic{d}{d}{d}ddddddc{i}{i}{i}iiiiic{d}{d}{d}dddddc{i}{i}{i}iiiic{d}{d}{d}ddddc{i}{i}{i}iiic{{d}iiiii}dddddc{i}{i}iicccc{{i}ddddd}iiiic{{d}iiiii}ddddc{{i}ddddd}iiic{{d}iiiii}dddc{{i}ddddd}iic{{d}iiiii}ddc{{i}ddddd}ic{{d}iiiii}dc{{i}ddddd}c{{d}iiiii}c{{i}ddddd}dc{{d}iiiii}ic{{i}ddddd}ddc{{d}iiiii}iic{{i}ddddd}dddc{{d}iiiii}iiic{{i}dddddd}iiiiiic{{d}iiiiii}ddddddc{{i}dddddd}iiiiic{{d}iiiiii}dddddc{{i}dddddd}iiiic{{d}iiiiii}ddddc{{i}dddddd}iiic{{d}iiiiii}dddc{{i}dddddd}iic{{d}iiiiii}ddc{{i}dddddd}ic{{d}iiiiii}dc{{i}dddddd}c{{d}iiiiii}c{{i}dddddd}dc{{d}iiiiii}ic{{i}dddddd}ddc{{d}iiiiii}iic{{i}dddddd}dddc{{d}iiiiii}iiic{i}{i}{i}iiiiiic{d}{d}{d}ddddddc{i}{i}{i}iiiiic{d}{d}{d}dddddc{i}{i}{i}iiiic{d}{d}{d}ddddc{i}{i}{i}iiic{{d}iiiii}dddddc{i}{i}iiccc{{i}ddddd}iiiiic{{d}iiiii}dddddc{{i}ddddd}iiiic{{d}iiiii}ddddc{{i}ddddd}iiic{{d}iiiii}dddc{{i}ddddd}iic{{d}iiiii}ddc{{i}ddddd}ic{{d}iiiii}dc{{i}ddddd}c{{d}iiiii}c{{i}ddddd}dc{{d}iiiii}ic{{i}ddddd}ddc{{d}iiiii}iic{{i}ddddd}dddc{{d}iiiii}iiic{{i}dddddd}iiiiiic{{d}iiiiii}ddddddc{{i}dddddd}iiiiic{{d}iiiiii}dddddc{{i}dddddd}iiiic{{d}iiiiii}ddddc{{i}dddddd}iiic{{d}iiiiii}dddc{{i}dddddd}iic{{d}iiiiii}ddc{{i}dddddd}ic{{d}iiiiii}dc{{i}dddddd}c{{d}iiiiii}c{{i}dddddd}dc{{d}iiiiii}ic{{i}dddddd}ddc{{d}iiiiii}iic{{i}dddddd}dddc{{d}iiiiii}iiic{i}{i}{i}iiiiiic{d}{d}{d}ddddddc{i}{i}{i}iiiiic{d}{d}{d}dddddc{i}{i}{i}iiiic{d}{d}{d}ddddc{i}{i}{i}iiic{{d}iiiii}dddddc{i}{i}iicc{{i}ddddd}iiiiiic{{d}iiiii}ddddddc{{i}ddddd}iiiiic{{d}iiiii}dddddc{{i}ddddd}iiiic{{d}iiiii}ddddc{{i}ddddd}iiic{{d}iiiii}dddc{{i}ddddd}iic{{d}iiiii}ddc{{i}ddddd}ic{{d}iiiii}dc{{i}ddddd}c{{d}iiiii}c{{i}ddddd}dc{{d}iiiii}ic{{i}ddddd}ddc{{d}iiiii}iic{{i}ddddd}dddc{{d}iiiii}iiic{{i}dddddd}iiiiiic{{d}iiiiii}ddddddc{{i}dddddd}iiiiic{{d}iiiiii}dddddc{{i}dddddd}iiiic{{d}iiiiii}ddddc{{i}dddddd}iiic{{d}iiiiii}dddc{{i}dddddd}iic{{d}iiiiii}ddc{{i}dddddd}ic{{d}iiiiii}dc{{i}dddddd}c{{d}iiiiii}c{{i}dddddd}dc{{d}iiiiii}ic{{i}dddddd}ddc{{d}iiiiii}iic{{i}dddddd}dddc{{d}iiiiii}iiic{i}{i}{i}iiiiiic{d}{d}{d}ddddddc{i}{i}{i}iiiiic{d}{d}{d}dddddc{i}{i}{i}iiiic{d}{d}{d}ddddc{i}{i}{i}iiic{{d}iiiii}dddddc{i}{i}iic{{i}dddd}dddc{{d}iiii}iiic{{i}ddddd}iiiiiic{{d}iiiii}ddddddc{{i}ddddd}iiiiic{{d}iiiii}dddddc{{i}ddddd}iiiic{{d}iiiii}ddddc{{i}ddddd}iiic{{d}iiiii}dddc{{i}ddddd}iic{{d}iiiii}ddc{{i}ddddd}ic{{d}iiiii}dc{{i}ddddd}c{{d}iiiii}c{{i}ddddd}dc{{d}iiiii}ic{{i}ddddd}ddc{{d}iiiii}iic{{i}ddddd}dddc{{d}iiiii}iiic{{i}dddddd}iiiiiic{{d}iiiiii}ddddddc{{i}dddddd}iiiiic{{d}iiiiii}dddddc{{i}dddddd}iiiic{{d}iiiiii}ddddc{{i}dddddd}iiic{{d}iiiiii}dddc{{i}dddddd}iic{{d}iiiiii}ddc{{i}dddddd}ic{{d}iiiiii}dc{{i}dddddd}c{{d}iiiiii}c{{i}dddddd}dc{{d}iiiiii}ic{{i}dddddd}ddc{{d}iiiiii}iic{{i}dddddd}dddc{{d}iiiiii}iiic{i}{i}{i}iiiiiic{d}{d}{d}ddddddc{i}{i}{i}iiiiic{d}{d}{d}dddddc{i}{i}{i}iiiic{d}{d}{d}ddddc{i}{i}{i}iiic{{d}iiiii}dddddc{{i}dd}c{{d}iiii}iic{{i}dddd}dddc{{d}iiii}iiic{{i}ddddd}iiiiiic{{d}iiiii}ddddddc{{i}ddddd}iiiiic{{d}iiiii}dddddc{{i}ddddd}iiiic{{d}iiiii}ddddc{{i}ddddd}iiic{{d}iiiii}dddc{{i}ddddd}iic{{d}iiiii}ddc{{i}ddddd}ic{{d}iiiii}dc{{i}ddddd}c{{d}iiiii}c{{i}ddddd}dc{{d}iiiii}ic{{i}ddddd}ddc{{d}iiiii}iic{{i}ddddd}dddc{{d}iiiii}iiic{{i}dddddd}iiiiiic{{d}iiiiii}ddddddc{{i}dddddd}iiiiic{{d}iiiiii}dddddc{{i}dddddd}iiiic{{d}iiiiii}ddddc{{i}dddddd}iiic{{d}iiiiii}dddc{{i}dddddd}iic{{d}iiiiii}ddc{{i}dddddd}ic{{d}iiiiii}dc{{i}dddddd}c{{d}iiiiii}c{{i}dddddd}dc{{d}iiiiii}ic{{i}dddddd}ddc{{d}iiiiii}iic{{i}dddddd}dddc{{d}iiiiii}iiic{i}{i}{i}iiiiiic{d}{d}{d}ddddddc{i}{i}{i}iiiiic{d}{d}{d}dddddc{i}{i}{i}iiiic{d}{d}{d}ddddc{i}{i}{i}iiic

Compared to others,  terrible!

Vyxal j, 10 bytes
kA¦RvṄøĊøR

Try it Online!
Very nice
Explained (old)
₄ƛkAẎṘṄ
₄ƛ        # over the range [1, 26]: (call each item n)
  kAẎ     #     push "ABCDE....XYZ"[0:n]
     ṘṄ   #     reverse and join on spaces
          # the -C flag auto-centers the top of the stack

6 bytes

OP has said no trailing spaces are allowed

Does this work for 7?

Brainfuck, 189 bytes
++[[+<]>+>++]<->>+[+[<]>>+<+]>>>-[-[-<]>>+<]>-<++++++++++<<<<<<<<[-[->+>+<<]>[-<+>]>[->>>>>>>.<<<<<<<]>>[->+>+<<]<+[->>>+<<<<+<+>>]<[->>>>-.>>>.<<<<<<<]<[->>+<<]>>>>>[-]<[-<+>]>>>.<<<<<<<<]
Try It Online!
(Using 8-bit wrapping)
I cannot put into words how much I hate this language.

R, 52 bytes
write(intToUtf8(outer(26:1,1:26,"<=")*90:65,T),1,26)

Try it online!
A different and (for now) golfier approach than this or that R answers.
To generate "exact text" as is required in kolmogorov-complexity challenges, there are usually two options in R: cat and write. cat is more flexible, as write is actually a wrapper around cat, but the advantage of write is that if you can construct your data in a rectangular (matrix) form, some of the verbosity of cat goes away, for instance, you get a newline without explicitly including it as you do in cat, which will then include an extra separator argument, which is usually undesirable. Since each line of the text here appears to be of variable width, write is not the first thing that comes to mind, and both of the other R answers are quite creative in getting around the shortcomings of cat. In particular, the fill argument is not one I'm familiar with, but will have to keep trying out.
The trick here is that write, like cat, separates elements by spaces. Since every line has the same number of spaces, if we can construct the right matrix of empty strings "" and capital letters, we can just use write to automatically put the spaces where they go.
My first attempt started by constructing the matrix directly:
R, 63 bytes
m=matrix(LETTERS,26,26);m[lower.tri(m)]="";write(m[26:1,],1,26)

Try it online!
This builds up a matrix of capital letters, then sets the lower triangle to empty strings, and finally flips vertically since write proceeds down the columns.
This is equally as long as Bart-Jan van Rossum's answer; I was going to post it since the approach was different, but when I went to read a comment on another completely unrelated challenge, I thought to try intToUtf8 instead.
Two things make this possible. Typically, intToUtf8 takes a vector of integers and converts them to a single string made up of their utf8 codepoints. There is also an optional argument, usually FALSE that when set to TRUE will instead return a vector of characters of the utf8 codepoints. The other trick is that intToUtf8(0) returns the empty string. So instead of constructing a matrix of "" and LETTERS, I constructed a matrix of codepoints, which ended up (finally) being shorter than the other R answers:
R, 61 bytes
write(intToUtf8((outer(1:26,1:26,"<=")*65:90)[26:1,],T),1,26)

Try it online!
Luckily, despite intToUtf8 returning a vector, write takes a ncolumns argument to specify how many columns wide it ought to be, which provides enough structure for write to print it correctly.
Finally, there are a couple of inefficient golfs which bring it to its current 52 byte form.

Jelly, 16 bytes
L26_⁶x;KU$
ØAÇƤY

Try it online!
This seems too long for Jelly, despite being terrible at ascii-art challenges

Haskell, 63 bytes
[(' '<$[c..'Y'])++foldl(\s->(:' ':s))"A"['B'..c]|c<-['A'..'Z']]

Try it online!

Japt, 29 bytes
;1o27@Bt0X)w)ò1)qS)ùS25+X})qR

Try it online!

This can be done in 11 bytes ;) Hint: it involves cumulative reduction.

@Shaggy Did I get your 11 byte solution?

Seeing as @EmbodimentofIgnorance got that, you can still golf this one to 17 bytes

PHP, 59 bytes
for($a=A;$i++<26;)echo str_pad('',26-$i),$s=$a++." $s","
";

Try it online!

sed 4.2.2 (with GNU exec extension), 58 bytes
s/^/bash -c 'echo {Z..A}'/e
:
s/^( *)\S([^\n]+)/\1\2\n&/
t

Try it online!

Pure sed 4.2.2, 71 bytes
s/^/ZYXWVUTSRQPONMLKJIHGFEDCBA/
s/\B/ /g
:
s/^( *)\S([^\n]+)/\1\2\n&/
t

Try it online!

Elixir, 70 bytes
r=90..65;for i<-0..25,do: IO.puts for j<-r,do: 65+i-j>-1&&[j,' ']||' '

Try it here

Wren, 125 119 bytes
Not very interesting until I read other answers.
for(i in 0..25){
System.write(" "*(25-i))
for(j in 0..i)System.write(" "+String.fromCodePoint(65+i-j))
System.print()
}

Try it online!

Javascript ES6, 105 bytes

[..."ZYXWVUTSRQPONMLKJIHGFEDCBA"].forEach((l,i,a)=>console.log(" ".repeat(25-i)+a.slice(25-i).join(" ")))

Python 3, 133 130 125 123 122 bytes
Not the shortest, but I wanted to try to make the output one single string
print('\n'.join((25-len(v)//2)*' '+v for v in(''.join(" "+chr(i)for i in range(90,64,-1))[i:52]for i in range(51,-1,-2))))

Try it online!

Perl 5, 30 bytes
$b[26+--$i]=$_,say"@b"for A..Z

Try it online!

Jelly, 12 bytes
ØAa⁶ḊÐƤżKƤUY

A full program which prints the result
Try it online!
How?
ØAa⁶ḊÐƤżKƤUY - Main Link: no arguments
ØA           - (set left to) uppercase alphabet  say:['A','B','C']
   ⁶         - space character                       ' '
  a          - AND (vectorises)                      [' ',' ',' ',]
     ÐƤ      - for postfixes:
    Ḋ        -   dequeue                             [[' ',' '],[' '],[]]
         Ƥ   - for prefixes (of left=alphabet):
        K    -   join with spaces                    [['A'],['A',' ','B'],['A',' ','B',' ','C']]
       ż     - zip together                          [[[' ',' '],['A']],[[' '],['A',' ','B']],[[],['A',' ','B',' ','C']]]
          U  - upend                                 [[[' ',' '],['A']],[[' '],['B',' ','A']],[[],['C',' ','B',' ','A']]]
           Y - join with newlines                    [[' ',' '],['A'],'\n',[' '],['B',' ','A'],'\n',[],['C',' ','B',' ','A']]
             - implicit, smashing print >>>  A
             -                          >>> B A
             -                          >>>C B A

C, 83 82 bytes
(−1 golfing thanks to ceilingcat)
main(c){for(char s[99]="",*t=s+98;*--t=c+64,printf("%*s\n",c+++25,t)<52;*--t=32);}

Builds the final string from end to beginning, printing all the unfinished versions.

Stax, 11 bytes
ùivK‼9⌂m¬╚─

Run and debug it

Python 3.8 (pre-release), 103 bytes
p=-1
x="abcdefghijklmnopqrstuvwxyz"
s=""
for a in[0]*26:print(" "*abs(26-p)+" ".join(s:=x[(p:=p+1)]+s))

Try it online!

Japt -R, 13 bytes
;Båi Ë¬¸ùBÊ+E

Test it
;Båi Ë¬¸ùBÊ+E
;B                :Uppercase alphabet
  å               :Cumulatively reduce by
   i              :  Prepending
     Ë            :Map each element at 0-based index E
      ¬           :  Split
       ¸          :  Join with spaces
        ù         :  Left pad with spaces to length
         BÊ+E     :    Length of B plus E

Pip -l, 22 bytes
sX26-_.(RAZ@<_Js)M\,26

Attempt This Online!
Explanation
sX26-_.(RAZ@<_Js)M\,26
                  \,26  ; Range of numbers from 1 through 26
                 M      ; Map this function to each:
  26-_                  ;  26 minus function argument
sX                      ;  That many spaces
      .(        )       ;  Concatenate to the following:
         AZ             ;  Uppercase alphabet
           @<_          ;  Slice left of function argument
        R               ;  Reverse
              Js        ;  Join on spaces

Pip, 21 bytes
L26PsX25-i.:RAZ@<UiJs

Attempt This Online!
Explanation
The guts are very similar to my Pip -l answer, but the iterative flagless approach turned out to be one byte shorter (at least until I implement that "center and pad with spaces" operator I've been planning).
L26PsX25-i.:RAZ@<UiJs
                      ; s is " ", i is 0, AZ is uppercase alphabet (implicit)
L26                   ; Loop 26 times:
    sX25-i            ;  String of (25-i) spaces
          .:          ;  Concatenate with:
                 Ui   ;   Increment i
             AZ@<     ;   Take that many characters from the front of AZ
            R         ;   Reverse
                   Js ;   Join on spaces
   P                  ;  Print that string