Skip to content

Commit c93470e

Browse files
committed
2 parents f812dcf + 177d597 commit c93470e

File tree

2 files changed

+15
-12
lines changed

2 files changed

+15
-12
lines changed

frontend/src/app/(home)/components/code-snippet/CodeSnippetHighlight.tsx

Lines changed: 14 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -6,16 +6,18 @@ import { useEffect, useState, useRef } from "react";
66

77
const CodeSnippetHighlight = () => {
88
const code = `
9-
class Solution:
10-
def twoSum(self, nums: List[int], target: int) -> List[int]:
11-
idxDict = {}
12-
for i, num in enumerate(nums):
13-
idxDict[num] = i
14-
15-
for i, num in enumerate(nums):
16-
diff = target - num
17-
if diff in idxDict and i != idxDict[diff]:
18-
return [i, idxDict[diff]]`;
9+
class Solution:
10+
def twoSum(self, nums: List[int], target: int) -> List[int]:
11+
idxDict = {}
12+
for i, num in enumerate(nums):
13+
idxDict[num] = i
14+
15+
for i, num in enumerate(nums):
16+
diff = target - num
17+
if diff in idxDict and i != idxDict[diff]:
18+
return [i, idxDict[diff]]
19+
20+
`;
1921

2022
const [displayedText, setDisplayedText] = useState(""); // Store the currently displayed text
2123
const currentCharIndexRef = useRef(0); // Track the current character index
@@ -52,7 +54,8 @@ const CodeSnippetHighlight = () => {
5254
borderRadius: "10px",
5355
}}
5456
>
55-
{displayedText}
57+
{displayedText}
58+
5659
</SyntaxHighlighter>
5760
);
5861
};

frontend/src/app/(home)/components/landing-page/LandingPage.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ const LandingPage = () => {
2727
return (
2828
<div className="flex flex-col min-h-full">
2929
<Navbar />
30-
<div className="grid grid-cols-2 gap-10 h-full items-center justify-center pl-10 pr-10">
30+
<div className="grid grid-cols-[1.45fr,1.55fr] gap-10 h-full items-center justify-center pl-10 pr-10">
3131
<div className="">
3232
<h1 className="text-6xl font-extrabold text-white pb-8">
3333
Collaborative Coding, <br></br> Competitive Results.

0 commit comments

Comments
 (0)