{"id":2483,"date":"2016-03-07T07:00:46","date_gmt":"2016-03-07T05:00:46","guid":{"rendered":"http:\/\/blue.pri.ee\/ttu\/?page_id=2483"},"modified":"2026-03-25T17:08:58","modified_gmt":"2026-03-25T15:08:58","slug":"homework-ii","status":"publish","type":"page","link":"https:\/\/blue.pri.ee\/ttu\/programming-ii\/homework-ii\/","title":{"rendered":"Homework II"},"content":{"rendered":"<div class=\"su-spoiler su-spoiler-style-fancy su-spoiler-icon-chevron su-spoiler-closed\" data-scroll-offset=\"0\" data-anchor-in-url=\"no\"><div class=\"su-spoiler-title\" tabindex=\"0\" role=\"button\"><span class=\"su-spoiler-icon\"><\/span>Explanations about keys (PK \/ FK)<\/div><div class=\"su-spoiler-content su-u-clearfix su-u-trim\">\n<p>PK (primary key) &#8211; Unique field or a group of fields in a table or a file that identifies a record (row in a file). Typically an integer or UUID is used, but it can be any value that is unique. One file or table can only have a single primary key. Each file or table has to have a primary key.<\/p>\n<p>FK (foreign key) &#8211; this is used to create relations to other tables or files. If a foreign key matches the primary key in another file or table, then these items are related to each other. One file or table can have multiple foreign keys and they&#8217;re not unique (can repeat).<\/p>\n<p>Foreign key and primary key form a relation between two files or database tables.<\/p>\n<p>E.g. one person can have multiple children; one receipt can have multiple products; one student can have multiple subject declarations; One person can own multiple properties; <\/div><\/div>\n<p>For homework II, you have to write a program based on the set requirements and document the work. The focus of this homework is implement dynamic memory allocation for data storage and writing a large, complex program.<\/p>\n<p><strong>This homework task is larger and more complex than any of the homework tasks before. Plan your time accordingly!<\/strong><\/p>\n<div id=\"ez-toc-container\" class=\"ez-toc-v2_0_82_2 counter-hierarchy ez-toc-counter ez-toc-grey ez-toc-container-direction\">\n<div class=\"ez-toc-title-container\">\n<span class=\"ez-toc-title-toggle\"><a href=\"#\" class=\"ez-toc-pull-right ez-toc-btn ez-toc-btn-xs ez-toc-btn-default ez-toc-toggle\" aria-label=\"Toggle Table of Content\"><span class=\"ez-toc-js-icon-con\"><span class=\"\"><span class=\"eztoc-hide\" style=\"display:none;\">Toggle<\/span><span class=\"ez-toc-icon-toggle-span\"><svg style=\"fill: #999;color:#999\" xmlns=\"http:\/\/www.w3.org\/2000\/svg\" class=\"list-377408\" width=\"20px\" height=\"20px\" viewBox=\"0 0 24 24\" fill=\"none\"><path d=\"M6 6H4v2h2V6zm14 0H8v2h12V6zM4 11h2v2H4v-2zm16 0H8v2h12v-2zM4 16h2v2H4v-2zm16 0H8v2h12v-2z\" fill=\"currentColor\"><\/path><\/svg><svg style=\"fill: #999;color:#999\" class=\"arrow-unsorted-368013\" xmlns=\"http:\/\/www.w3.org\/2000\/svg\" width=\"10px\" height=\"10px\" viewBox=\"0 0 24 24\" version=\"1.2\" baseProfile=\"tiny\"><path d=\"M18.2 9.3l-6.2-6.3-6.2 6.3c-.2.2-.3.4-.3.7s.1.5.3.7c.2.2.4.3.7.3h11c.3 0 .5-.1.7-.3.2-.2.3-.5.3-.7s-.1-.5-.3-.7zM5.8 14.7l6.2 6.3 6.2-6.3c.2-.2.3-.5.3-.7s-.1-.5-.3-.7c-.2-.2-.4-.3-.7-.3h-11c-.3 0-.5.1-.7.3-.2.2-.3.5-.3.7s.1.5.3.7z\"\/><\/svg><\/span><\/span><\/span><\/a><\/span><\/div>\n<nav><ul class='ez-toc-list ez-toc-list-level-1 ' ><li class='ez-toc-page-1 ez-toc-heading-level-3'><a class=\"ez-toc-link ez-toc-heading-1\" href=\"https:\/\/blue.pri.ee\/ttu\/programming-ii\/homework-ii\/#The_task\" >The task<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-3'><a class=\"ez-toc-link ez-toc-heading-2\" href=\"https:\/\/blue.pri.ee\/ttu\/programming-ii\/homework-ii\/#Requirements_for_the_program\" >Requirements for the program<\/a><ul class='ez-toc-list-level-4' ><li class='ez-toc-heading-level-4'><a class=\"ez-toc-link ez-toc-heading-3\" href=\"https:\/\/blue.pri.ee\/ttu\/programming-ii\/homework-ii\/#Requirements_for_the_standards_and_environment\" >Requirements for the standards and environment<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-4'><a class=\"ez-toc-link ez-toc-heading-4\" href=\"https:\/\/blue.pri.ee\/ttu\/programming-ii\/homework-ii\/#General_requirements_for_the_solution\" >General requirements for the solution<\/a><\/li><\/ul><\/li><li class='ez-toc-page-1 ez-toc-heading-level-3'><a class=\"ez-toc-link ez-toc-heading-5\" href=\"https:\/\/blue.pri.ee\/ttu\/programming-ii\/homework-ii\/#Input_data_file_requirements\" >Input data file requirements<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-3'><a class=\"ez-toc-link ez-toc-heading-6\" href=\"https:\/\/blue.pri.ee\/ttu\/programming-ii\/homework-ii\/#Documentation_template\" >Documentation template<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-3'><a class=\"ez-toc-link ez-toc-heading-7\" href=\"https:\/\/blue.pri.ee\/ttu\/programming-ii\/homework-ii\/#Documentation_requirements\" >Documentation requirements<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-3'><a class=\"ez-toc-link ez-toc-heading-8\" href=\"https:\/\/blue.pri.ee\/ttu\/programming-ii\/homework-ii\/#Extra_task_for_bonus_points\" >Extra task for bonus points<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-3'><a class=\"ez-toc-link ez-toc-heading-9\" href=\"https:\/\/blue.pri.ee\/ttu\/programming-ii\/homework-ii\/#Deadlines\" >Deadlines<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-3'><a class=\"ez-toc-link ez-toc-heading-10\" href=\"https:\/\/blue.pri.ee\/ttu\/programming-ii\/homework-ii\/#Submitting_Your_work\" >Submitting Your work<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-3'><a class=\"ez-toc-link ez-toc-heading-11\" href=\"https:\/\/blue.pri.ee\/ttu\/programming-ii\/homework-ii\/#Result_and_feedback\" >Result and feedback<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-3'><a class=\"ez-toc-link ez-toc-heading-12\" href=\"https:\/\/blue.pri.ee\/ttu\/programming-ii\/homework-ii\/#Fixing_your_homework\" >Fixing your homework<\/a><\/li><\/ul><\/nav><\/div>\n<h3><span class=\"ez-toc-section\" id=\"The_task\"><\/span>The task<span class=\"ez-toc-section-end\"><\/span><\/h3>\n\n<!-- iframe plugin v.6.0 wordpress.org\/plugins\/iframe\/ -->\n<iframe loading=\"lazy\" src=\"https:\/\/blue.pri.ee\/ttu\/files\/iax0584\/kodutoo2\/index_en.html\" width=\"100%\" height=\"100\" scrolling=\"yes\" class=\"iframe-class\" frameborder=\"0\"><\/iframe>\n\n<h3><span class=\"ez-toc-section\" id=\"Requirements_for_the_program\"><\/span>Requirements for the program<span class=\"ez-toc-section-end\"><\/span><\/h3>\n<p>The code must adhere to all of the best practices introduced during Programming 1 and Programming 2.<\/p>\n<p>Your solution can include topics that have not been covered, as long as they are used correctly and well documented. You need to provide motivation why those concepts were used so that it clear, that you have mastered those topics.<\/p>\n<h4><span class=\"ez-toc-section\" id=\"Requirements_for_the_standards_and_environment\"><\/span><span id=\"Requirements_for_the_standards_and_environment\" class=\"ez-toc-section\"><\/span>Requirements for the standards and environment<span class=\"ez-toc-section-end\"><\/span><\/h4>\n<p>The program must be written in the C programming language. You are permitted to use the C90 and C99 standards. Using newer standards (C11, C17, C23) is permitted, if it provides additional value. This must be explained in the report.<\/p>\n<p>In addition to the standard C libraries, you are allowed to use C POSIX and GNU C libraries and extensions. Use of any other third party libraries must be agreed upon separately.<\/p>\n<p>Your program will be compiled and tested in a Linux environment, equivalent to the one in the lab computers (OpenSUSE SLED-15 SP5, using GCC-12) or with the latest Ubuntu version (Ubuntu Linux 25.10, using GCC-15 or later). Compatibility with Windows or MacOS is not required.<\/p>\n<h4><span class=\"ez-toc-section\" id=\"General_requirements_for_the_solution\"><\/span><span id=\"General_requirements_for_the_solution\" class=\"ez-toc-section\"><\/span><strong>General requirements for the solution<\/strong><span class=\"ez-toc-section-end\"><\/span><\/h4>\n<ul>\n<li>Code must be divided into more than a single file. Exact number of files is and code division left to the author of the solution.\n<ul>\n<li>Minimally it must be split into a header and a code file<\/li>\n<li>If multiple code files exist or code is divided between multiple directories, a Makefile must be provided for compilation<\/li>\n<\/ul>\n<\/li>\n<li>The data must be read from two separate files into memory<\/li>\n<li>Default data file names must be coded into the program. You are allowed to use command line arguments, but they must not be necessary to use your program.<\/li>\n<li>Data must be kept in dynamically created data structures\n<ul>\n<li>You can use dynamic arrays, linked lists, trees etc.<\/li>\n<li>The amount of memory allocated must be dependent on the number of records in the input file<\/li>\n<li>The amount of memory allocated must match what is required to keep the data in memory<\/li>\n<li>Program must work with a variable amount of records &#8211; adding or removing records from files should not cause issues<\/li>\n<li>There must not exist any arbitrary size limitation for the input files<\/li>\n<li>Variable length arrays inside of the struct (e.g. strings) must be allocated dynamically to match exactly what they require to be stored. Fixed length arrays and strings must be static<\/li>\n<li>Limitations do not apply to temporary buffers. You can use both static and dynamic memory for buffers.<\/li>\n<\/ul>\n<\/li>\n<li>Structures used must be appropriate for the given task\n<ul>\n<li>At minimum, all information from the files should be stored in the structures<\/li>\n<li>You can add members to the structure as needed<\/li>\n<li>You can define additional structures to support your task as needed<\/li>\n<li>If your data contains <strong>time and\/or date<\/strong>, you must either use a nested structure to store them or pick an appropriate data type from <span class=\"lang:c highlight:0 decode:true crayon-inline\">time.h<\/span>\u00a0 library<\/li>\n<\/ul>\n<\/li>\n<li>All actions by your program must be repeatable <strong>without exiting the program<\/strong>!\n<ul>\n<li>Create a menu that allows performing all tasks listed in your variant<\/li>\n<li>Each task in your variant creates at least one menu option for your program.<\/li>\n<li>You are allowed to add additional menu options that are not defined in the variant (e.g. for debugging).<\/li>\n<li>The result of each action is displayed on the screen<\/li>\n<li>There must be an option to gracefully exit the program<\/li>\n<\/ul>\n<\/li>\n<li>If a task requires you to modify, add or delete data, the modifications must be persistent (written to the data files used by the program). If the program is executed again, it must use the updated data<\/li>\n<li>Your program must include logging\n<ul>\n<li>Every action by the user must be logged<\/li>\n<li>One log entry per line<\/li>\n<li>All log entries must include a date and a time<\/li>\n<li>Log must also include non-visible actions such as starting of the program, successful reading of input file, etc.<\/li>\n<li>\u00a0All previous logs must be retained.<\/li>\n<\/ul>\n<\/li>\n<li>The program must provide basic user experience (UX)\n<ul>\n<li>If a user is sent to a nested menu (i.e. second level menu), they must be able to return from it without completing the action.<\/li>\n<li>The program must notify the user of any errors encountered in a clear manner. The message must be precise and helpful to the user to solve the issue. All error messages must be written to the <span class=\"lang:c highlight:0 decode:true crayon-inline \">stderr<\/span>\u00a0 standard stream.<\/li>\n<li>When user input is expected, the prompt must be clear to the user. If the input needs to be in a specific format, you must provide the user with the expected format. If applicable, add an example of how the input should be written.<\/li>\n<li>If the program contains searching, filtering or grouping features and there are no matches the set criteria, it must be written explicitly to the user.<\/li>\n<\/ul>\n<\/li>\n<li>No memory leaks, wasted or unreleased resources. All resources must be returned to the system by you before the program exits. Use Valgrind to check.<\/li>\n<\/ul>\n<h3><span class=\"ez-toc-section\" id=\"Input_data_file_requirements\"><\/span>Input data file requirements<span class=\"ez-toc-section-end\"><\/span><\/h3>\n<ul>\n<li>In total, you must create and use two data files.\u00a0Each data file <b>can <\/b>only contain the fields described in your task variant.<\/li>\n<li>The data in the files is connected by a PK-FK (primary key &#8211; foreign key) key-pair\n<ul>\n<li>The entities are tied with a zero to many multiplicity (e.g. <strong>one<\/strong> student can declare <strong>multiple<\/strong> subjects; a student can also have no subjects declared)<\/li>\n<\/ul>\n<\/li>\n<li>Data model for the input files is <strong>created<\/strong>\u00a0by the author of the solution based on their capabilities and knowledge. This includes data field delimiters, order of data fields, data field contents,\u00a0 complexity,\u00a0 etc. The chosen data model and the decisions for it are\u00a0<strong>documented<\/strong>\u00a0by the author in the document provided alongside the program.<\/li>\n<li>The data records will be created by the author of the solution and submitted with the solution.\n<ul>\n<li>There must be at least 10 records the first file (containing only the primary key) and at least 15 records in the second file (containing the FK referring to the records in the first file).<\/li>\n<li>If the author submits multiple sets of input files to demonstrate different capabilities of the program, the minimum data length limits are only applied to one of the sets.<\/li>\n<\/ul>\n<\/li>\n<\/ul>\n<h3><span class=\"ez-toc-section\" id=\"Documentation_template\"><\/span>Documentation template<span class=\"ez-toc-section-end\"><\/span><\/h3>\n<p>Use the same templates as you used in Programming 1, Homework 1 (<a href=\"https:\/\/blue.pri.ee\/ttu\/programming-i\/homework-i\/#Report\">https:\/\/blue.pri.ee\/ttu\/programming-i\/homework-i\/<\/a>) and adjust it to fit the requirements of this homework.<\/p>\n<h3><span class=\"ez-toc-section\" id=\"Documentation_requirements\"><\/span>Documentation requirements<span class=\"ez-toc-section-end\"><\/span><\/h3>\n<p><strong>Focus on structured documentation!\u00a0<\/strong> Avoid story-telling (except summary).<\/p>\n<ul>\n<li>Title page<\/li>\n<li>Declaration of originality<\/li>\n<li>List of abbreviations and terms (can be omitted if not present)<\/li>\n<li>Table of contents<\/li>\n<li>List of figures<\/li>\n<li>List of tables<\/li>\n<li>The task description (variant)<\/li>\n<li>Detailed description of the solution (<strong>no walls of text!<\/strong>)\n<ul>\n<li>A brief description of what the program does.<\/li>\n<li>Program workflow \u2013 In what order are things done? (Do\u00a0<strong>not<\/strong> go into details! About half a page)<\/li>\n<li>Project structure &#8211; names of files, short description. If code is divided into directories, explain the division.<br \/>\nRecommended: show output of <span class=\"lang:c highlight:0 decode:true crayon-inline \">tree<\/span>\u00a0 application<\/li>\n<li>Document the structures\n<ul>\n<li>Purpose of the structure<\/li>\n<li>Details (member name, data type, description, example value), formatted as a table<\/li>\n<\/ul>\n<\/li>\n<li>Document the enumerations (if applicable)\n<ul>\n<li>Name, description and possible values of the <span class=\"lang:c highlight:0 decode:true crayon-inline \">enum<\/span><\/li>\n<\/ul>\n<\/li>\n<li>Special situation \/ error handling\n<ul>\n<li>Description of issue<\/li>\n<li>What&#8217;s the status of it &#8211; did you solve it, work around it, is it still present in the code<\/li>\n<li>If it was mitigated, how did you mitigate it.<\/li>\n<\/ul>\n<\/li>\n<\/ul>\n<\/li>\n<li>Data file structure\n<ul>\n<li>Structure of one record (data field order, separators between fields, separators between records<\/li>\n<li>Data fields \u2013 name, data type, example of a value, meaning of data (semantics), any limitations (e.g. length, value range, illegal values)<\/li>\n<li>Present a single data record from the file as an example.<\/li>\n<\/ul>\n<\/li>\n<li>Extra task (if applicable)<\/li>\n<li>Summary\n<ul>\n<li>Write a few sentences about your approach to the task and progression during it<\/li>\n<li>Write a few sentences about the task itself and the complexity of it<\/li>\n<li>If possible, give an estimate on the workload<\/li>\n<li>Would you recommend using this task in the future? Would you change anything about it and if so, what?<\/li>\n<li>Additional comments, emotions, thoughts<\/li>\n<\/ul>\n<\/li>\n<li>References (can be omitted if not present)\n<ul>\n<li>Use IEEE style for references<br \/>\nEnglish official reference: <strong><a href=\"https:\/\/journals.ieeeauthorcenter.ieee.org\/wp-content\/uploads\/sites\/7\/IEEE_Reference_Guide.pdf\">https:\/\/journals.ieeeauthorcenter.ieee.org\/wp-content\/uploads\/sites\/7\/IEEE_Reference_Guide.pdf<\/a><br \/>\n<\/strong>Reference help by TalTech (in Estonian): <strong><a href=\"https:\/\/haldus.taltech.ee\/sites\/default\/files\/2024-05\/IEEE_stiilis_viitamine_2024%20%281%29.pdf\">https:\/\/haldus.taltech.ee\/sites\/default\/files\/2024-05\/IEEE_stiilis_viitamine_2024%20%281%29.pdf<\/a><\/strong><\/li>\n<li>Everything that wasn\u2019t covered within the subject and that you didn\u2019t create on your own.<\/li>\n<li>This includes help from a friend or a colleague:\u00a0<strong><a href=\"https:\/\/libraryguides.vu.edu.au\/ieeereferencing\/personalcommunication\">https:\/\/libraryguides.vu.edu.au\/ieeereferencing\/personalcommunication<\/a><\/strong><\/li>\n<li>Use of AI tools must be referenced (i.e. ChatGPT, Gemini, &#8230;)<\/li>\n<li>All references must be precise.\u00a0<em>References such as stackoverflow.com or google.com are meaningless. It must be directly to the page where you got the information from.<\/em><\/li>\n<\/ul>\n<\/li>\n<li>Screen capture(s) of the program\n<ul>\n<li>Screenshots can be added as an appendix or embedded within the write up of the solution \u2013 in this case you can extend the length by the amount of pictures<\/li>\n<li>The screenshots should show both normal operation and operation in various error situations<\/li>\n<\/ul>\n<\/li>\n<\/ul>\n<h3><span class=\"ez-toc-section\" id=\"Extra_task_for_bonus_points\"><\/span>Extra task for bonus points<span class=\"ez-toc-section-end\"><\/span><\/h3>\n<p>It is possible to earn up to 15 bonus points from the task. In order to get any points, you must include the added features to the report. It is possible to obtain partial bonus points if not all requirements are met.<\/p>\n<p>To get bonus points, the following requirements must also be met in addition to the base requirements<\/p>\n<ul>\n<li>Code must be well structured. Makefile must be provided to compile the solution.\n<ul>\n<li>Code must be divided into multiple code and header files<\/li>\n<li>You can&#8217;t have all the files left in the root directory of the project &#8211; some effort must be put into at least basic division of files into subdirectories<\/li>\n<li>Makefile must minimally use CFLAGS and CC variables<\/li>\n<li>Makefile must minimally contain recipes for\u00a0 <span class=\"lang:c highlight:0 decode:true crayon-inline \">all<\/span>\u00a0 and <span class=\"lang:c highlight:0 decode:true crayon-inline \">clean<\/span>\u00a0.<\/li>\n<li>Makefile must be written in such a way that it would support recompilation of only modified source files<\/li>\n<li>The rest of the complexity for the Makefile is up to the author<\/li>\n<\/ul>\n<\/li>\n<li>Logging must be created as an\u00a0<strong>independent\u00a0<\/strong>library\n<ul>\n<li>It must be designed as an independent library, contained within itself (no use of <span class=\"lang:c highlight:0 decode:true crayon-inline \">extern<\/span> )!<\/li>\n<li>It must support setting the name of the log file<\/li>\n<li>It must support different logging levels, implemented as an enumerable type<\/li>\n<li>It must support setting the logging level. Logs with lower priority than the set level are not logged.<\/li>\n<li>All logging events must include the logging level.<\/li>\n<li>All state variables (log file name, logging level, &#8230;) for the library must be stored within the library. You are not allowed to directly access the variables from your main project, but instead must use the functions implemented in the logging library.<\/li>\n<\/ul>\n<\/li>\n<li>Program must be able to work with text fields containing multiple words<\/li>\n<li>You must add a level 1 heading to the documentation called \u201cExtra task\u201d.\n<ul>\n<li>Describe the added features<\/li>\n<li>Explain how your logging library could be used in other projects by other developers. Provide a specification for all the key (important) functions for someone who would like to use your library &#8211; i.e. the functions that they can call from your library, excluding the internal library functions not intended to be used by others.<\/li>\n<li>Explain the weaknesses and strenghts of your chosen data file format. Are there any limitations to what the data can contain?<\/li>\n<li>Walk through the reasoning for what you chose to include, or deliberately omit, in the Makefile. List all the recipes that can be called in your Makefile with a short description. Do not list the intermediate recipes that are only called by other recipes, which are not intended to be called directly.<\/li>\n<\/ul>\n<\/li>\n<\/ul>\n<h3><span class=\"ez-toc-section\" id=\"Deadlines\"><\/span>Deadlines<span class=\"ez-toc-section-end\"><\/span><\/h3>\n<p><span style=\"color: #ff0000;\"><strong>A complete homework must be submitted no later than 26.04.2026<\/strong><\/span><\/p>\n<p>Each day passed the homework deadline will deduct 1 point from the final homework score. The late penalty is capped at 30 points.<\/p>\n<p>If we have questions about the submitted homework or are not sure about the original author of this work, we will grade this with 0p. In this case, the work must be defended.<\/p>\n<p>If it becomes necessary, we will enforce the rules and guidelines of [<a href=\"https:\/\/haldus.taltech.ee\/sites\/default\/files\/2020-10\/Terviktekst_IT-teaduskonna%20%C3%B5ppuri%20akad%20tavade%20rikkumise%20ja%20v%C3%A4%C3%A4ritu%20k%C3%A4itumise%20menetlemise%20kord_ENG.pdf\">Procedure for processing a student\u2019s violation of academic practices and contemptible behavior in the School of Information Technologies<\/a>]\n<p data-select-like-a-boss=\"1\"><span style=\"color: #ff0000;\"><strong>We will only accept Your homework until the lockdown date (check introduction slides). Past that, submitting your homework will not be possible.<\/strong><\/span><\/p>\n<h3><span class=\"ez-toc-section\" id=\"Submitting_Your_work\"><\/span>Submitting Your work<span class=\"ez-toc-section-end\"><\/span><\/h3>\n<p>The homework needs to be submitted in the Moodle course under Homework 2.<\/p>\n<p><strong>Files required:<\/strong><\/p>\n<ol>\n<li>Documentation (PDF)<\/li>\n<li>All of the code files (.c and .h) to compile the program.<\/li>\n<li>Data files required to run the program<\/li>\n<\/ol>\n<p>Depending on your solution, a Makefile may need to be included (e.g. multiple code files, different C standard, extra task, ..)<\/p>\n<p>Naming schema: <span class=\"lang:c highlight:0 decode:true crayon-inline \">HW2_lastname[_filename]<\/span><\/p>\n<p>Naming schema only applies to files directly uploaded to Moodle. It does not apply to files stored in the archive. Even if you upload the source code as an archive, the PDF file must be uploaded separately!<\/p>\n<p>Example (separate files):<\/p>\n<p style=\"padding-left: 30px;\">HW2_Tiib.c<br \/>\nHW2_Tiib.h<br \/>\nHW2_Tiib_data.txt<br \/>\nHW2_Tiib_report.pdf<\/p>\n<p>Example (project as an archive):<\/p>\n<p>Example:<\/p>\n<p style=\"padding-left: 30px;\">HW2_Tiib_project.zip<br \/>\nHW2_Tiib_report.pdf<\/p>\n<p><strong>NB! If you changed the names of the files before uploading, make sure your solution still compiles and works with the new names!<\/strong><\/p>\n<h3><span class=\"ez-toc-section\" id=\"Result_and_feedback\"><\/span>Result and feedback<span class=\"ez-toc-section-end\"><\/span><\/h3>\n<p>After your work has been checked and graded, you will see the result and feedback on Moodle (visible from your gradebook only!). If everything was well done, feedback may be absent.<\/p>\n<h3><span class=\"ez-toc-section\" id=\"Fixing_your_homework\"><\/span><span id=\"Fixing_your_homework\" class=\"ez-toc-section\"><\/span><span id=\"Fixing_your_homework\" class=\"ez-toc-section\"><\/span>Fixing your homework<span class=\"ez-toc-section-end\"><\/span><\/h3>\n<p>You are allowed to fix and improve your homework score until the date of homework lockdown. All fixed submissions are subject to defense.<\/p>\n<p>To fix your homework, first go through your feedback. Then contact your teacher and agree upon the process of how this homework can be fixed.<\/p>\n<p>NB! If fixing the homework changes more than half of the original homework, it is considered as submitting a completely new homework, from which minus points can be deducted from depending on the time of submission.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>For homework II, you have to write a program based on the set requirements and document the work. The focus of this homework is implement dynamic memory allocation for data storage and writing a large, complex program. This homework task is larger and more complex than any of the homework tasks before. Plan your time &hellip; <a href=\"https:\/\/blue.pri.ee\/ttu\/programming-ii\/homework-ii\/\" class=\"more-link\">Loe edasi <span class=\"screen-reader-text\">Homework II<\/span> <span class=\"meta-nav\">&rarr;<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"parent":2340,"menu_order":3,"comment_status":"closed","ping_status":"closed","template":"page-templates\/code-width.php","meta":{"footnotes":""},"class_list":["post-2483","page","type-page","status-publish","hentry"],"_links":{"self":[{"href":"https:\/\/blue.pri.ee\/ttu\/wp-json\/wp\/v2\/pages\/2483","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/blue.pri.ee\/ttu\/wp-json\/wp\/v2\/pages"}],"about":[{"href":"https:\/\/blue.pri.ee\/ttu\/wp-json\/wp\/v2\/types\/page"}],"author":[{"embeddable":true,"href":"https:\/\/blue.pri.ee\/ttu\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/blue.pri.ee\/ttu\/wp-json\/wp\/v2\/comments?post=2483"}],"version-history":[{"count":25,"href":"https:\/\/blue.pri.ee\/ttu\/wp-json\/wp\/v2\/pages\/2483\/revisions"}],"predecessor-version":[{"id":11331,"href":"https:\/\/blue.pri.ee\/ttu\/wp-json\/wp\/v2\/pages\/2483\/revisions\/11331"}],"up":[{"embeddable":true,"href":"https:\/\/blue.pri.ee\/ttu\/wp-json\/wp\/v2\/pages\/2340"}],"wp:attachment":[{"href":"https:\/\/blue.pri.ee\/ttu\/wp-json\/wp\/v2\/media?parent=2483"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}