This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <iostream> | |
#include <algorithm> | |
#include <vector> | |
int main() { | |
unsigned int entryCount; | |
cin >> entryCount; | |
if (entryCount == 0) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <iostream> | |
#include <algorithm> | |
#include <vector> | |
int main() { | |
unsigned int entryCount; | |
cin >> entryCount; | |
if (entryCount == 0) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
BIN=lab4 | |
CC=gcc | |
OBJ=lab4.o | |
all: $(BIN) | |
$(BIN): $(OBJ) | |
%.o: %.c |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/ksh | |
if [ ! $# -eq 1 ] | |
then | |
echo "Wrong input" | |
exit 1 | |
fi | |
USER="$1" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/ksh | |
IFS="`printf ''`" | |
USAGE="usage: symlink.sh <file>" | |
get_metadata() { | |
perl -se 'use File::stat; $file=lstat($filename); if (defined $file) { print $file->ctime . " " . $file->ino . "\n"; } ' -- -filename="$1" | |
} | |
readlink() { | |
perl -se 'use File::Spec; print File::Spec->rel2abs( readlink($file) )' -- -file="$1" | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/ksh | |
LOGFILE=script.log | |
function process_input { | |
local ret=$1 | |
if [[ "$ret" == "~"* ]]; then | |
echo 1>&2 "Введите 'y' если под ~ подразумевается $HOME" | |
read confirm | |
fi |
NewerOlder