The general idea of this program is that given a grammar, construct any random string that follows the grammar rules. It is guaranteed that all the strings produced will be valid.
For the grammar, all the non-terminals are positioned on the left side while the equivalent values are positioned on the right side.
This is the grammar provided to us by our professor. This is a grammar for a simple calculator. The assumption here is that the grammar is Context Free and that the string has a finite length. Read more…
The program assumes that you will be providing Context-Free Grammar, otherwise it will not work properly. The idea of the program is to break a sentence down to its atomic elements. It follows the concept of String Rewriting System.
Given a sentence: abbabab
and grammar rules:
- ab -> S
- aS -> S
- Sb -> S
- SS -> S
The program determines whether the sentence can be parsed or not. It can be parsed if the sentence follows the grammar rules. Read more…
This is a Simple Finite State Parser that checks whether is an English sentence is syntactically correct or not based on the grammar provided by my teacher.
The following is the Finite State Diagram of the grammar:
The program reads from a file a dictionary of valid words which also contains the type of the word. See sample below: Read more…
Open the Registry Editor (regedit via Run command) and go to this directory:
Each network location is represented by a folder entry under this directory.
If you want to set up again the network locations when the network adapter connects to the network, delete all the subfolders of Profiles folder.
If you want to rename the network location, click on the right subfolder and edit the key named ProfileName and input the name you desire for the network location.
My group and I are performing an experiment in one of our subjects. We are using the SimStudent program which is locally installed in approximately 80 machines. We needed a way to copy all the logs of all the program instances and store them in a network storage.
This is the script I made. This will only work in Windows.
@echo off REM Written by: Yancy Vance M. Paredes, March 18, 2014 REM Go to the directory where the log folder is located cd simstudent\SimStAlgebraV8 REM Prompt the user to enter the correct student number SET /p STUDENT_ID="Enter student ID (ex: 02 [with leading zero]): " REM Prompt the user to enter the session number SET /p SESSION_ID="Session No. (1, 2 or 3): " REM Prepare the target path based on the user's input SET TEMP_PATH=Session %SESSION_ID%\ADDU02%STUDENT_ID% REM Make sure to update this one to point to the UITO network storage SET TARGET_PATH=M:\logs\%TEMP_PATH%\ REM echo %TARGET_PATH% REM Copy the file to the network storage, prompt for overwriting REM and copy everything inside the log folder to the new directory xcopy log "%TARGET_PATH%" /s /-y
The assumption here is that the script is located just outside the SimStudent directory.
If your Samsung device comes with a magnetic sensor, you can calibrate it.
The first thing that you have to do is go to the Diagnostic Menu by issuing the code *#0*# . Afterwards, go to Sensor. You will know if the magnetic sensor is calibrated or not. See the picture below.
The value should be 3 and not 1. By the way, this screenshot was taken from my Note 10.1. To calibrate it, just shake your device until it becomes 3. Just wait for a few minutes before the value changes. See the picture below. Read more…
If you are using GRUB as your boot loader and you want to change the default operating system that is highlighted in the list, just follow these simple steps:
You should do this on your Linux machine. My current setup: dual boot of Windows 8.1 and Ubuntu 13.10.
Open the terminal and issue the following command:
sudo nano /etc/default/grub
Look for the variable GRUB_DEFAULT. Set the value to any integer value. It works similarly with the index of an array in C or Java.
In the list above, you can set the value from 0 to 3, inclusive.
After changing the file, save it and issue the following to update the GRUB:
Finally, restart your system to see if it works.
If you try installing Dropbox on Ubuntu 13.10, you will notice that the Indicator is missing. According to forums, it has something to do with the Dropbox application since Unity 3 does not recognize it properly.
To fix it, just install the following package:
sudo apt-get install libappindicator1
Afterwards, log out then log in so that the changes will take effect.
If you want to modify the path to the home directory of a user, issue the following command in the terminal:
sudo usermod -d /new/home/path -m username
This will work if the user you want to modify is not logged in.