Skip to content

Commit c659829

Browse files
Update weeklycontent.html
1 parent 3a6fc39 commit c659829

File tree

1 file changed

+47
-47
lines changed

1 file changed

+47
-47
lines changed

weeklycontent.html

Lines changed: 47 additions & 47 deletions
Original file line numberDiff line numberDiff line change
@@ -2736,18 +2736,18 @@ <h3>1. What are header files in C programming?</h3>
27362736
<ol>
27372737
<li>Files that contain the main function</li>
27382738
<li>Files that are executed before the program runs</li>
2739-
<li>Files that contain function declarations and macros</li>
2739+
<li><strong>Files that contain function declarations and macros</strong></li>
27402740
<li>Files used for memory allocation</li>
27412741
</ol>
27422742
</div>
27432743

27442744
<div class="content-block">
27452745
<h3>2. Which of the following appears valid at first glance but is actually an invalid variable declaration in C?</h3>
27462746
<ol>
2747-
<li>`char str[20] = "Hello";`</li>
2748-
<li>`int @salary = 5000;`</li>
2749-
<li>`float salary2025 = 99999.99;`</li>
2750-
<li>`int NumberOfStudents = 50;`</li>
2747+
<li>char str[20] = "Hello";</li>
2748+
<li><strong>int @salary = 5000;</strong></li>
2749+
<li>float salary2025 = 99999.99;</li>
2750+
<li>int NumberOfStudents = 50;</li>
27512751
</ol>
27522752
</div>
27532753

@@ -2766,7 +2766,7 @@ <h3>3. What could be the outcome when the following C program is compiled and ex
27662766
<ol>
27672767
<li>It prints Hello, World! to the screen.</li>
27682768
<li>It throws a compilation error due to missing semicolon.</li>
2769-
<li>It prints Hello, World!\n as-is, including \n.</li>
2769+
<li><strong>It prints Hello, World!\n as-is, including \n.</strong></li>
27702770
<li>It waits for user input before printing anything.</li>
27712771
</ol>
27722772
</div>
@@ -2776,7 +2776,7 @@ <h3>4. A programmer wants to create a custom data type to represent a person's d
27762776
<ol>
27772777
<li>Arrays</li>
27782778
<li>Pointers</li>
2779-
<li>Structures</li>
2779+
<li><strong>Structures</strong></li>
27802780
<li>Functions</li>
27812781
</ol>
27822782
</div>
@@ -2787,17 +2787,17 @@ <h3>5. Which of the following is *NOT* a valid category of functions in C?</h3>
27872787
<li>Library Functions</li>
27882788
<li>User-Defined Functions</li>
27892789
<li>Recursive Functions</li>
2790-
<li>Loop-Control Functions</li>
2790+
<li><strong>Loop-Control Functions</strong></li>
27912791
</ol>
27922792
</div>
27932793

27942794
<div class="content-block">
27952795
<h3>6. Which of the following is NOT a control structure in C?</h3>
27962796
<ol>
2797-
<li>`if-else`</li>
2798-
<li>`for` loop</li>
2799-
<li>`switch`</li>
2800-
<li>`print`</li>
2797+
<li>if-else</li>
2798+
<li>for loop</li>
2799+
<li>switch</li>
2800+
<li><strong>print</strong></li>
28012801
</ol>
28022802
</div>
28032803

@@ -2830,7 +2830,7 @@ <h3>7. Which of the following code snippets will cause an error or unexpected be
28302830
printf("20 or more");
28312831
</code></pre>
28322832
<ol>
2833-
<li>A</li>
2833+
<li><strong>A</strong></li>
28342834
<li>B</li>
28352835
<li>C</li>
28362836
<li>D</li>
@@ -2854,7 +2854,7 @@ <h3>8. What could be a possible behavior when this C program runs?</h3>
28542854
</code></pre>
28552855
<ol>
28562856
<li>It will print "Value at ptr: 10" and then "Value at ptr after increment: 11".</li>
2857-
<li>It will print "Value at ptr: 10" and then "Value at ptr after increment: 20".</li>
2857+
<li><strong>It will print "Value at ptr: 10" and then "Value at ptr after increment: 20".</strong></li>
28582858
<li>It will cause a segmentation fault because `ptr` is incremented.</li>
28592859
<li>It will print the memory addresses of the array elements.</li>
28602860
</ol>
@@ -2865,7 +2865,7 @@ <h3>9. A structure in C has a char member followed by an int member. However, th
28652865
<ol>
28662866
<li>The structure is packed tightly in memory.</li>
28672867
<li>The structure is aligned to a 4-byte boundary.</li>
2868-
<li>The structure has extra padding for memory alignment.</li>
2868+
<li><strong>The structure has extra padding for memory alignment.</strong></li>
28692869
<li>The structure is compressed to reduce its size.</li>
28702870
</ol>
28712871
</div>
@@ -2875,18 +2875,18 @@ <h3>10. What is the main characteristic of a do...while loop compared to a while
28752875
<ol>
28762876
<li>It checks the condition before executing the loop body</li>
28772877
<li>It never executes if the condition is false</li>
2878-
<li>It executes the loop body at least once before checking the condition</li>
2878+
<li><strong>It executes the loop body at least once before checking the condition</strong></li>
28792879
<li>It cannot use break statements</li>
28802880
</ol>
28812881
</div>
28822882

28832883
<div class="content-block">
28842884
<h3>11. Which keyword is used to return a value from a function?</h3>
28852885
<ol>
2886-
<li>`return`</li>
2887-
<li>`send`</li>
2888-
<li>`break`</li>
2889-
<li>`exit`</li>
2886+
<li><strong>return</strong></li>
2887+
<li>send</li>
2888+
<li>break</li>
2889+
<li>exit</li>
28902890
</ol>
28912891
</div>
28922892

@@ -2903,7 +2903,7 @@ <h3>12. What will be the output of the following C code?</h3>
29032903
}
29042904
</code></pre>
29052905
<ol>
2906-
<li>1 2 3 0 0</li>
2906+
<li><strong>1 2 3 0 0</strong></li>
29072907
<li>1 2 3 garbage garbage</li>
29082908
<li>Compilation error</li>
29092909
<li>1 2 3 4 5</li>
@@ -2923,7 +2923,7 @@ <h3>13. Which of the following best describes what the pointer `ptr` does in the
29232923
</code></pre>
29242924
<ol>
29252925
<li>It stores the value of a, not its address.</li>
2926-
<li>It holds the address of a and can be used to access or modify a's value.</li>
2926+
<li><strong>It holds the address of a and can be used to access or modify a's value.</strong></li>
29272927
<li>It points to a completely unrelated memory location.</li>
29282928
<li>It causes a segmentation fault when dereferenced.</li>
29292929
</ol>
@@ -2933,7 +2933,7 @@ <h3>13. Which of the following best describes what the pointer `ptr` does in the
29332933
<h3>14. A programmer wants to store a flag that can have one of three possible values (0, 1, or 2) in a structure. What feature of C structures can be used to optimize memory usage in this case?</h3>
29342934
<ol>
29352935
<li>Bitwise operations</li>
2936-
<li>Bit fields</li>
2936+
<li><strong>Bit fields</strong></li>
29372937
<li>Unions</li>
29382938
<li>Enumerations</li>
29392939
</ol>
@@ -2942,10 +2942,10 @@ <h3>14. A programmer wants to store a flag that can have one of three possible v
29422942
<div class="content-block">
29432943
<h3>15. What is the correct way to declare a pointer to a function that returns `int` and takes two `int` parameters?</h3>
29442944
<ol>
2945-
<li>`int *func(int, int);`</li>
2946-
<li>`int (*func)(int, int);`</li>
2947-
<li>`int (*func(int, int));`</li>
2948-
<li>`(*int func)(int, int);`</li>
2945+
<li>int *func(int, int);</li>
2946+
<li><strong>int (*func)(int, int);</strong></li>
2947+
<li>int (*func(int, int));</li>
2948+
<li>(*int func)(int, int);</li>
29492949
</ol>
29502950
</div>
29512951

@@ -2962,7 +2962,7 @@ <h3>16. What is the output of this code?</h3>
29622962
</code></pre>
29632963
<ol>
29642964
<li>Address of a</li>
2965-
<li>10</li>
2965+
<li><strong>10</strong></li>
29662966
<li>Compilation error</li>
29672967
<li>0</li>
29682968
</ol>
@@ -2982,7 +2982,7 @@ <h3>17. What will be the output of the following C code?</h3>
29822982
</code></pre>
29832983
<ol>
29842984
<li>Techie</li>
2985-
<li>chie</li>
2985+
<li><strong>chie</strong></li>
29862986
<li>hie</li>
29872987
<li>Compilation error</li>
29882988
</ol>
@@ -3006,15 +3006,15 @@ <h3>18. What will happen if the file "myfile.txt" cannot be opened in write mode
30063006
<ol>
30073007
<li>The program will skip writing and directly read from the file.</li>
30083008
<li>The program will crash without any message.</li>
3009-
<li>The program will display "Error opening file!" and exit.</li>
3009+
<li><strong>The program will display "Error opening file!" and exit.</strong></li>
30103010
<li>The program will create a backup file and continue.</li>
30113011
</ol>
30123012
</div>
30133013

30143014
<div class="content-block">
30153015
<h3>19. A programmer wants to represent a person's address as part of their overall details. What feature of C structures can be used to group the address details (street, city, state, zip) together within the person's structure?</h3>
30163016
<ol>
3017-
<li>Nested structures</li>
3017+
<li><strong>Nested structures</strong></li>
30183018
<li>Arrays of structures</li>
30193019
<li>Pointers to structures</li>
30203020
<li>Functions that return structures</li>
@@ -3038,18 +3038,18 @@ <h3>20. What does the expression `found - str` do after `char *found = strchr(st
30383038
<ol>
30393039
<li>Adds an offset to the character pointer</li>
30403040
<li>Returns the memory address of 'a'</li>
3041-
<li>Computes the index of 'a' in the string</li>
3041+
<li><strong>Computes the index of 'a' in the string</strong></li>
30423042
<li>Returns a null pointer</li>
30433043
</ol>
30443044
</div>
30453045

30463046
<div class="content-block">
30473047
<h3>21. How can you access structure members?</h3>
30483048
<ol>
3049-
<li>Using the comma `,` operator</li>
3050-
<li>Using the dot `.` operator</li>
3051-
<li>Using the star `*` operator</li>
3052-
<li>Using the at `@` operator</li>
3049+
<li>Using the comma (,) operator</li>
3050+
<li><strong>Using the dot (.) operator</strong></li>
3051+
<li>Using the star (*) operator</li>
3052+
<li>Using the at (@) operator</li>
30533053
</ol>
30543054
</div>
30553055

@@ -3071,7 +3071,7 @@ <h3>22. What will happen when the following code is executed?</h3>
30713071
}
30723072
</code></pre>
30733073
<ol>
3074-
<li>The program creates data.txt and writes "Hello World!"</li>
3074+
<li><strong>The program creates data.txt and writes "Hello World!"</strong></li>
30753075
<li>The program prints "Error opening file."</li>
30763076
<li>The program throws a compile-time error</li>
30773077
<li>The program opens the file in append mode and adds "Hello World!" at the end</li>
@@ -3096,7 +3096,7 @@ <h3>23. What will happen if "myfile.txt" does not exist when the program tries t
30963096
<ol>
30973097
<li>It creates a new empty file named "myfile.txt".</li>
30983098
<li>It reads from a temporary file instead.</li>
3099-
<li>It returns NULL and prints an error message.</li>
3099+
<li><strong>It returns NULL and prints an error message.</strong></li>
31003100
<li>It appends default text into the file.</li>
31013101
</ol>
31023102
</div>
@@ -3106,7 +3106,7 @@ <h3>24. A programmer wants to read data from a file in C. What is the first step
31063106
<ol>
31073107
<li>Reading data from the file using `fread()`</li>
31083108
<li>Closing the file using `fclose()`</li>
3109-
<li>Opening the file using `fopen()`</li>
3109+
<li><strong>Opening the file using `fopen()`</strong></li>
31103110
<li>Writing data to the file using `fwrite()`</li>
31113111
</ol>
31123112
</div>
@@ -3156,7 +3156,7 @@ <h3>25. Why is `fgets()` used for reading the student name instead of `scanf("%s
31563156
<ol>
31573157
<li>Because `scanf("%s")` reads newline characters</li>
31583158
<li>Because `fgets()` is faster than `scanf()`</li>
3159-
<li>Because `fgets()` can read names with spaces</li>
3159+
<li><strong>Because `fgets()` can read names with spaces</strong></li>
31603160
<li>Because `scanf()` automatically closes the file</li>
31613161
</ol>
31623162
</div>
@@ -3185,17 +3185,17 @@ <h3>25. Why is `fgets()` used for reading the student name instead of `scanf("%s
31853185
// --- CONTROL KEYWORD HERE ---
31863186
// Define a variable to store the ID of the disabled week
31873187
// Set this to the week you want to disable (e.g., 'week4', 'week2', or null if no week is disabled)
3188-
let disabledWeekId = null; // Changed from 'null' to null to ensure no week is disabled
3188+
let disabledWeekId = 'week7'; // Changed from 'null' to null to ensure no week is disabled
31893189

31903190
// Define an array of disabled days for a given week (e.g., ['tuesday', 'thursday'] for week1)
31913191
const disabledDays = {
31923192
// Uncomment these lines and specify days if you want to disable specific days within weeks
3193-
// 'week1': [], // Example: No disabled days for Week 1
3194-
// 'week2': [],
3195-
// 'week3': [],
3196-
// 'week4': [],
3197-
// 'week5': [],
3198-
// 'week6': [],
3193+
'week1': ['monday','tuesday','wednesday','thursday','friday'], // Example: disabled days for Week 1
3194+
'week2': ['monday','tuesday','wednesday','thursday','friday'],
3195+
'week3': ['monday','tuesday','wednesday','thursday','friday'],
3196+
'week4': ['monday','tuesday','wednesday','thursday','friday'],
3197+
'week5': ['monday','tuesday','wednesday','thursday','friday'],
3198+
'week6': ['monday','tuesday','wednesday','thursday','friday'],
31993199
// 'week7': [], // Mindmash - no disabled days here for now
32003200
};
32013201
// --- END CONTROL KEYWORD ---

0 commit comments

Comments
 (0)