It's a very strong model for what it is trained! Bravo!

#7
by codingquark-personal - opened

I gave it quite a few hard problems, within the domain, focused on programming. It performs exceptionally well IMO. Here are a few noteworthy prompts:

https://gist.github.com/codingquark/8df7f68eaafdabbae3498f7e083a0861
https://gist.github.com/codingquark/beaf63593c96ff52bf289d44167433b2
https://gist.github.com/codingquark/091e0b04bee6ccc9f53e80d9e0587c03

Just to give an idea quickly in case you don't want to go through the gists, these are the prompts:

  • Place 4 rooks on a 6Γ—6 chessboard so that no two share a row or column, and no rook sits on a cell (i,i) of the main diagonal (rows and columns numbered 1–6). How many such placements are there? Give the final answer as \boxed{N}
  • Write a self-contained Python function count_dominant(a: list[int]) -> int returning the number of contiguous subarrays that are dominant: a subarray is dominant if its maximum element is strictly greater than the sum of all its other elements. For a length-1 subarray there are no other elements, so the "sum of others" is 0 (so it's dominant iff its single element is > 0). The array may contain negatives and duplicates. Aim for better than the brute-force O(n^2) and state the complexity you reach. Explain your approach, then hand-trace on a=[3,-1,2,-5,4], a=[5,5,1], and a=[-2,-3,-1], giving the return value for each.
  • Let N be the number of functions f:{1,…,8}β†’{1,…,8} such that f(f(x))=f(x) for every x, and such that there are exactly 3 values x with f(x)=xf. Find N and give it as \boxed{N}.

Sign up or log in to comment