하드 디스크를 2개의 파티션으로 분할해서, 윈도우8이랑 윈도우7을 멀티 부팅으로 사용해 오다가

어떤 필요성이 생겨서, 윈도우8을 밀고, 이 자리에 윈도우7 x86판을 깔기로 했어요.

윈도우 까는게 뭐 힘들게 있냐만은, 문제는 윈도우8쪽 파티션 여기 저기에 잔뜩 들어있는

고용량의 각종 압축 파일들과 미디어파일들!

이걸 어디다 임시로 옮겼다가 윈도우8 파티션을 깨끗이 포맷하고, 윈도우7을 깔면 가장 깔끔하고

좋지만. 용량이 장난이 아녀서 어디 임시로 갖다 둘 데도 없고, 한다 해도 시간이 엄청 걸릴게 불을

보듯 환하다.

 

그래서, 윈도우8의 주요 디렉토리를 rename 시키고, 기존 파티션에 덮어 씌우기로 윈7을

새로 깔았다. 여기까지는 좋은데, 이전 윈도우의 파일/디렉토리가 새 윈도우에서 깔끔하게

지워지지를 않는다. 왜 이런 일이 생기는지 구구절절 설명할 수도 있지만,

해결 방법만 간단하게 기술한다.

 

먼저,

지워지지 않는 디렉토리 바로 상위 디렉토리에 run as administrator로 연, commnd prompt에서

(1) takeown /f directory_name /r /d y

빈간까지 정확하게 입력하고, 디렉토리 네임은 자기가 지울 것으로 바꾸면 된다

이게 제대로 되면 아래같은 결과가 보인다

SUCCESS: The file (or folder): “C:\win8\WinSxS\x86_wwf-cwetargets_i_31bf3856ad36
4e35_6.2.9200.16384_none_9d06d2e3aa3f6202\Workflow.Targets” now owned by user “j
ungdh-x86\Administrator”.

(2) icacls directory_name /grant Administrator:D /t

여기서도 물론 디렉토리 네임을 자기걸로 해주고, 어드미니스트레이터는 실제 사용자 이름이다

이 과정도 제대로 되면 다음과 같은 결과가 보인다

processed file: WinSxS\Manifests\amd64_microsoft-windows-help-privstatement_31bf
3856ad364e35_6.2.9200.16384_none_a48bdfca2465881b.manifest

당연히 개별 디렉토리/파일 이름은 상황에 따라 달라진다.

 

여기까지 했으면, 해당 디렉토리를 “탐색기”에서 지우면 지워진다!!


* excursion : 짧은여행, 소풍

(ex) excursion train : 유람 열차, lunar excursion module(lem) : 달착륙선, alarums and excursions : 야단법석

(cf.) airng oneself, a waling tour, an excursion : 소풍

* confer: (vt)수여하다, (vi)의논하다

(ex) confer an award on a person, He asked for some time to confer with his lawyers

* infer: (vt)추론하다 ( = deduce)

(ex) I inferred from what she said that you have not been well.

* deteriorate : 악화되다

(ex) His health deteriorated.

* brake : 브레이크

(ex) put on the brakes, hit the brakes, apply the brakes : 브레이크를 밟다; 견제하다(비유), jam(slam) on the brakes : 급브레이크를 밟다

* screech : scream, 날카로운 소리를 내다

(ex) The birds screeched out of surprise, screech to a halt : 끽 소리를 내며 멈추다, 급정지하다

* mop : 대걸레

(ex) Mrs. mop : 청소부아줌마, give sth a mop : ~에 대걸레를 걸다

* mob : 군중

(ex) mob psychology : 군중심리

* flop : 쿵쓰러지다, 변절하다

(ex) flop down on the couch : 소파에 털썩 주저앉다, flop over to the other party :  변절하여 반대당으로 가다

* flip : 튀겨날리다, 넘기다(뒤집다)

(ex) flip the ash off a cigar, flip a person on the ear(=flip a person’s ear), He flipped the page open, He flipped the page closed, flip at a horse with a whip, make a flip(가볍게 치다), give a hamburger a flip(햄버거를 한 번 뒤집다)


set

English 2014. 3. 8. 13:06

1.

set a lamp on the TV

set a vase on its side (꽃병을 눕혀 놓다)

set a stick against the wall (벽에 기대 세우다)

2.

a ring set with diamonds

set plants (묘목을 심다)

set a post in the ground

set the glass in the window

3.

set a custard (커스터드를 굳히다)

He set his mouth in a straight line

His face was set (표정이 굳어 있었다)

The mortar is set (회반죽이 굳었다)

* motor(/ou/), mortar(/au/)

4.

set a hen (닭이 알을 품게하다)

5.

set the detective on the case

set pickets around the camp (야영지 주변에 보초를 배치하다)

6.

set a time limit

set a speed limit

set a regular pace

set the fashion (유행을 만들어내다)

7.

set a cup to one’s lips (컵에 입을 대다)

set pen to paper (쓰기 시작하다)

set a match to the papers (신문지에 성냥으로 불을 붙이다)

8.

set a price on sth (~에 가격을 매기다)

I set this rare book at $100,000.

9.

set a poem(words) to music (곡에 가사를 붙이다)

10.

set a person a prblem (남에게 문제를 과하다)

set homework to students (학생들에게 숙제를 내주다)

set easy questions in an examinations (쉬운 시험 문제를 내다)

11.

set one’s direction to the west

set one’s mind on success

He set his mind on resignation (그만두기로 마음을 굳히다)

12.

set the trash on fire

set a person free

set one’s room in order

set one’s mind at ease

set an engine going(in motion)

The noise set the dogs barking

13.

set a trap

set the table (식사준비를 하다)

lay the table (식사준비를 하다, 영국식)

set the oven timer for 10 minutes

set one’s clock by the radio

 

14.

The glue has set (아교가 굳었다)

His eyes set resolutely (결연한 눈빛이 보였다)

* be resolute for peace. He is resolute to fight.

The suit sets well

The suit sets badly

The wind sets (to the) south

Her mind sets to revenge

The dog sets well (그 개는 사냥감을 잘 가르킨다)

The sun has set in the west

 

15.

a six-piece tea set (6인분의 홍차 세트)

a set of proposals

a complete set of Shakespeare

a set of criminals (범인 일당)

influential sets (유력자들)

the set of one’s features (이목구비)

the set of a coat (웃옷의 매무새)

The set of  his political beliefs was clear to everyone (정치적 신념의 경향)

a stage set (무대 장치)

a three-set match (3세트 게임, 테니스에서)


Grove

English 2014. 3. 8. 13:05

1. 작은 숲( < forest), 과수원(orchard)

a picnic grove

a bamboo grove

an orange grove

a citrus orchard

an apple orchard

2. 거리(가로수가 있는 거리명)

 

* plantation

a coffee plantation – 커피농장

plantation songs – 흑인 노동요

a fir plantation – 전나무 숲



Word & Usage

English 2014. 3. 8. 13:05

1. similat & comparable

She looks similar to her mother. (O)

She looks similar with her mother. (X)

The weather in Spain can be comparable with the weather in Porgugal. (O)

The weather in Spain can be comparable to that in Porgugal. (O)

2. manifest

What is an id? Is it a psychological term referring to the part of the mind in which innate instinctive impulses and primary processes are manifest? Not in this case: it stands for identifier, and it’s pronounced “eye dee”.



(1) C++의 경우,

#include <iostream>
using namespace std;

class ShareVar
{
    static int num1;
public:
    static int num2;
    void setnum(int i) { num1 = i; }
    void shownum() { cout << num1 << " " << num2 << endl; }
};

int ShareVar::num1; // define num1
int ShareVar::num2;
   
int main()
{
    ShareVar a, b;
   
    a.shownum();
    b.shownum();
   
    a.setnum(10);
    a.shownum();
    ShareVar::num2 = 10;
    b.shownum();
   
    return 0;

}

C++의 경우 cpp 파일에서 class_name::static_member_name;

과 같이 해당 정적 멤버의 저장 공간을 따로 선언해 줘야 한다는걸 기억해야 한다.

 

(2) Java의 경우,

class Car {
  String Name;
  static int CarNum = 0;
  Car(String aName) {
    Name = aName;
    CarNum++;
  }
}

class JavaExam {
  pubic static void main(String args[]) {
    Car Pride = new Car("프라이드");
    Car Matis = new Car("마티즈");
    Car Carnical = new Car("카니발");
    System.out.println("차 " + Car.CarNum + "대 구입함");
  }
}

Java의 경우, 특별히 조심해야할 사항은 없어 보인다


SDL (Simple Directmedia Layer)는 멀티 플랫폼 GUI 개발 및 게임 개발에 흔히 쓰인다

각설하고,

SDL을 Visual Studio와 함께 사용할 때 꼼꼼히 설정을 해주지 않으면

Link Time에서 이런저런 에러가 발생한다

 

아래 사항을 꼼꼼히 확인하자

 

(1) SDL을 특정 Working Directory에 설치한다(압축을 푼다)

편의상 f:\work\sdl_12 폴더에 풀었다고 치자

(2) Visual Studio 2008에서 Empty Project를 생성한다

Win32로 해도 가능하지만, 편의상 Console Project로 한다

(3) 생성한 프로젝트의 소스파일 tree에 예를 들어 main.cpp를 생성한다

그리고 당연히 이 안에는,

int main(int argc, char* argv[])

로 시작하는 샘플 코드를 넣어둔다

(4) 추가 포함 파일 경로를 설정한다

vs2008 (한글) 기준으로: 도구->옵션->프로젝트및솔루션->VC++디렉터리->포함파일

에 f:\work\sdl_12\include 를 추가한다

(5) 추가 라이브러리 파일 경로를 설정한다

vs2008 (한글) 기준으로: 도구->옵션->프로젝트및솔루션->VC++디렉터리->라이브러리파일

에 f:\work\sdl_12\lib 를 추가한다

(6) 런타임라이브러리를 설정한다

vs2008 (한글) 기준으로: 프로젝트->(프로젝트이름)속성->구성속성->C/C++->코드생성

에 "런타임 라이브러리"를 "다중 스레드 DLL”로 설정한다. 여기서 DEBUG 여부는 don’t care

(7) 추가종속성을 설정한다

vs2008 (한글) 기준으로: 프로젝트->(프로젝트이름)속성->구성속성->링커->입력

의 "추가종속성" 부분에 sdl.lib 파일과 sdlmain.lib 파일을 추가한다

한편! 여기서 바로 밑에 있는 "모든 기본 라이브러리 무시" 부분은 "아니오"로 해준다!!!

자! 여기까지 했으면 솔루션 Build 하고서 실행파일이 생긴 곳에 SDL.DLL을 같이 넣어주거나

또는 시스템 디렉토리(난 이 방법 선호하지 않으이!)에 넣어주고 실행 파일을 기동해 본다

 

위와 같이 정확하게 해주면 100% 동작한다.

p.s. : console project가 아닌 win32 project로 생성했으면 main() 대신

WinMain()만 사용하면 된다고 하나 테스트 해보지 않았다


[for C++ ]

class base

{

    int a;

public:

    base(int x) { a = x; }

};

class derived : public base

{

    int b;

public:

    derived(int x, int y) : base(y) { b = x;}

};

[for java]

class base {

  int a;

  public base(int x) { a = x; }

}

class derived extends base {

  int b;

  public derived(int x, int y) { super(y); b = x; }

}


typedef 문을 ,와 함께 쓰는 경우가 종종 있다
생각해 보면 의미는 당연한데 처음에는 좀 헷갈릴 수 있다

--------------------------------------------------
#include <iostream>

using namespace std;

typedef struct {
  int a;
  int b;
  int c;
} mytype, *pmytype;

int main()
{
  mytype var_a;
  pmytype ptr_a;

  ptr_a = &var_a;

  var_a.a = 10;
  var_a.b = 20;
  ptr_a->c = 30;

  cout << "values of var_a is " << ptr_a->a << " " 
       << ptr_a->b << " " << var_a.c << endl;

  return 0;
}



리눅스에서는.

    FILE *fp; 에서

    fp->_fileno 로 file desctiptor 를 뜻하는 integer  값을 얻을 수 있고

 

반면 윈도우에서는,

  FILE *fp; 에서

  fp->_file 을 사용해야 함